locked
PersonInfo.SelectedRecord.GetItem RRS feed

  • Question

  • Trying to check if an item exists in Medications.

    If an item doesn't exist using PersonInfo.SelectedRecord.GetItem, then does it return null?

    I'm trying to create a condition that testing if the item exists in Medication.

    Medication medication_exists_in_hv = (Medication)PersonInfo.SelectedRecord.GetItem(temp_wc_id, HealthRecordItemSections.All);
    if (medication_exists_in_hv == null)
    {

    Thanks,
    Gary
    Friday, February 5, 2010 3:27 AM

Answers

  • PersonInfo.SelectedRecord.GetItem  will return null if the item with specified key does not exist in HealthVault.

    Raj


    Raj HealthVault Developer Tool http://xray.getrealconsulting.com
    • Marked as answer by Gary Isaac Friday, February 5, 2010 4:03 PM
    Friday, February 5, 2010 10:53 AM