DisplayValue DisplayValue DisplayValue Class

Definition

Represents the display value for a length, weight, or other type of measurement.

public class DisplayValue : Microsoft.Health.ItemTypes.HealthRecordItemData
type DisplayValue = class
    inherit HealthRecordItemData
Public Class DisplayValue
Inherits HealthRecordItemData
Inheritance

Remarks

A display value differs from a value in that it is the value as entered by the user rather than the value converted to a base unit. The unit used can also reference the unit through the HealthVault dictionary code.

Single-valued display values ("15 pounds") should be expressed using the Value and Units properties.

Multi-valued display values ("12 pounds 3 ounces") can be expressed using the Text property, but should also be expressed using value and units ("12.25 pounds").

Constructors

DisplayValue() DisplayValue() DisplayValue()

Creates a new instance of the DisplayValue class with empty values.

DisplayValue(Double) DisplayValue(Double) DisplayValue(Double)

Creates a new instance of the DisplayValue class with the specified value.

DisplayValue(Double, String) DisplayValue(Double, String) DisplayValue(Double, String)

Creates a new instance of the DisplayValue class with the specified value and units.

DisplayValue(Double, String, String) DisplayValue(Double, String, String) DisplayValue(Double, String, String)

Creates a new instance of the DisplayValue class with the specified value, units, and units code.

Properties

Text Text Text

Gets or sets the display text.

Units Units Units

Gets or sets the units of measure as defined by the user.

UnitsCode UnitsCode UnitsCode

Gets or sets the code used in the HealthVault Dictionary to represent the units.

Value Value Value

Gets or sets the display value.

Methods

ParseXml(XPathNavigator) ParseXml(XPathNavigator) ParseXml(XPathNavigator)

Populates the data for the display value from the XML.

ToString() ToString() ToString()

Retrieves a string representation of the display value.

WriteXml(String, XmlWriter) WriteXml(String, XmlWriter) WriteXml(String, XmlWriter)

Writes the display value to the specified XML writer.

Applies to