ISApproval.CaseID

Description

ID of the linked case.

Syntax

object.CaseID

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

Return Value

int

Example

Display the number of the approvals loaded on the basis of the selected filter, the titles of the linked cases with their IDs and the dates when these cases were opened.

Dim aPatient
Dim aFilter
Dim aApproval
Dim aApprovals
Dim aMessage
Dim i

Set aPatient = Profile.SelectPatient
set aFilter = Profile.CreateApprovalsFilter
aFilter.Patient = aPatient
set aApprovals = Profile.LoadApprovals(aFilter)

aMessage = "Approvals Count = " & aApprovals.Count
for i = 0 to aApprovals.Count - 1
  set aApproval = aApprovals.Item(i)
  aMessage = aMessage & vbNewLine & "The approval for " & aPatient.SurnameFirstName &_
    " was added on " & aApproval.DateTimeAdded 
  if aApproval.CaseID <> 0 then
    set aCase = Profile.OpenCase(aApproval.CaseID) 
    aMessage = aMessage & vbNewLine & "       - The case '" & aCase.CaseTitle &_
      "' (ID: " & aCase.ID & ") was opened on " & aCase.OpenedOn & vbNewLine 
  end if      
next      

Profile.MsgBox(aMessage)                   
Note:

In Profile Client v8 on User Interface Case ID cannot be found, but Case can be found in Patient > Alter Patient > Approvals > Approval Edit > Case or in Financial > Approvals > Approvals > Case.

Version information

Added in v8.5.0