New SDK release

This is a minor SDK release.

User Quotas 

The HealthVault platform puts a quota limit on how much information can be stored in a HealthVault record. With this SDK release, some of that information is now exposed.

HealthRecordInfo (usually accessed through PersonInfo.SelectedRecord) gets the following new properties:

  • int64? QuotaInBytes;
  • int64? QuotaUsedInBytes;

All of the data types (ie everything derived from HealthRecordItem) now provides:

  • int GetSizeInBytes();

that can be used to determine how big a specific item is. It's recommended that you only use this information when you are working with large items, and note that all the values that you get (both for quota and size) are approximate and may change slightly over time. Here's some sample code that is quota-aware:

try
{
    myRecord.Update(myHealthItem)
}
catch(HealthServiceRecordQuotaExceededException)
{
    Response.Write(“Could not update the item because of your record size limit. Log into <a href=\”https://account.healthvault.com/”>HealthVault Account</a> for further assistance.”);
}

ToString() enhancements

ToString() implementations have been added to a lot of the types derived from HealthRecordItem.

A few items we missed

There were a few items that we missed in the last release notes:

  • There is a new CardiacProfile type
  • There is a new RespiratoryProfile type
  • The immunization type can now take an approximate date in the constructor
  • In addition to the step data, AerobicData also now stores ElevationGain and ElevationLoss