Export (0) Print
Expand All

GetVocabulary Method (HealthServiceConnection, VocabularyKey, Boolean)

HealthVault
Retrieves a list of vocabulary items for the specified vocabulary and culture.

Namespace: Microsoft.Health
Assembly: Microsoft.Health (in Microsoft.Health.dll) Version: 2.1.0.0 (1.15.1003.9505)

public static Vocabulary GetVocabulary(
	HealthServiceConnection connection,
	VocabularyKey vocabularyKey,
	bool cultureIsFixed
)

Parameters

connection
Type: Microsoft.Health..::..HealthServiceConnection
The connection to use for this operation. The connection must have application capability.
vocabularyKey
Type: Microsoft.Health..::..VocabularyKey
A key identifying the vocabulary requested.
cultureIsFixed
Type: System..::..Boolean
HealthVault looks for the vocabulary items for the culture info specified using Culture. If cultureIsFixed is set to false and if items are not found for the specified culture, items for the default fallback culture are returned. If cultureIsFixed is set to true, fallback will not occur, and if items are not found for the specified culture, empty strings are returned.

Return Value

The specified vocabulary and its items, or empty strings.

ExceptionCondition
System..::..ArgumentNullException The vocabularyKey is null.
Microsoft.Health..::..HealthServiceException There is an error in the server request.
-Or-
The requested vocabulary is not found on the server.
-Or-
The requested vocabulary does not contain representations for its items for the specified culture when cultureIsFixed is true.
-Or-
There is an error loading the vocabulary.
Show:
© 2015 Microsoft