This function returns all sharing consents of the case.
object.LoadSharingConsents()
Part | Attribute | Type | Description |
---|---|---|---|
object |
Required | The object always implements the
ISCase interface |
Display the number of the cases loaded on the basis of the selected filter, their titles, some information about their sharing consents, the dates and time when these cases were opened.
Dim aPatient
Dim aFilter
Dim aCases, aCase
Dim aSharingConsents
Dim aConsent
Dim aPartition
Dim i, j
Dim aMessage
Set aPatient = Profile.SelectPatient
set aFilter = Profile.CreateCasesFilter
aFilter.Patient = aPatient
set aCases = Profile.LoadCases(aFilter)
aMessage = "The number of the cases for " & aPatient.SurnameFirstName &_
" = " & aCases.Count
for i = 0 to aCases.Count -1
set aCase = aCases.Item(i)
set aSharingConsents = aCase.LoadSharingConsents
aMessage = aMessage & vbNewLine & (i + 1) & ") " & aCase.CaseTitle &_
" was opened on " & aCase.OpenedOn
if aSharingConsents.Count > 0 then
aMessage = aMessage & vbNewLine & " Sharing Consents: "
for each aConsent in aSharingConsents
aMessage = aMessage & vbNewLine &_
" -Consent has " & aConsent.SharedPartitionCount & " Shared Partition(s): "
for j = 0 to aConsent.SharedPartitionCount - 1
set aPartition = aConsent.SharedPartition(j)
aMessage = aMessage & aPartition.Name & " (" & aPartition.Code & ")"
next
next
end if
next
Profile.MsgBox(aMessage)
In Profile Client v8 on User Interface Sharing Consents can be found in
.