ISEncounterFilter.DiagnosisCode

Description

This filter property is used to load the collection of encounters by the specified diagnosis code.

Syntax

object.DiagnosisCode

Part Attribute Type Description
object Required
The object always implements the ISEncounterFilter interface

Return Value

string

Example

Display the number of the encounters loaded on the basis of the selected filter, their dates and contact subjects.

Dim aPatient
Dim aFilter  
Dim aEncounters, aEncounter
Dim i, j
Dim aContact
Dim aMessage

Set aPatient = Profile.SelectPatient 
set aFilter = Profile.CreateEncounterFilter 
aFilter.PatientId = aPatient.ID 
aFilter.DiagnosisCode = "ASTHMA" 
set aEncounters = aPatient.LoadEncounters(aFilter)

aMessage = "Encounters Count = " & aEncounters.Count

for i = 0 to aEncounters.Count - 1
  set aEncounter = aEncounters.Item(i)
  aMessage = aMessage & vbNewLine & "The encounter on " & aEncounter.date & ":"
  if aEncounter.Contacts.Count <> 0 then
    for j = 0 to aEncounter.Contacts.Count -1
      set aContact = aEncounter.Contacts.Item(j)
      aMessage = aMessage & vbNewLine & "    -Contact Subject: " & aContact.Subject
    next
  end if  
next 
Profile.MsgBox(aMessage)  
Note:

In Profile Client v8 on User Interface Diagnosis Code can be found in Clinical > Medical Record > Encounters > Open encounter > Encounter Properties > Diagnosis field.

Version information

Added in v7.8.0