ISCDOTransaction.PrivacyRoleID

Description

ID of the privacy role for the CDO transaction.

Syntax

object.PrivacyRoleID

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

Return Value

int

Example

Display some information about the CDO transactions, including IDs of the privacy roles for the CDO transactions.

Dim aPatient
Dim aFilter 
Dim aCDOTransactions, aCDOTransaction
Dim aProv
Dim aParam
Dim aRoles, aRole
Dim i
Dim aMessage

Set aPatient = Profile.SelectPatient
set aFilter = Profile.CreateCDOTransFilter
aFilter.PatientId = aPatient.Id
set aCDOTransactions = Profile.LoadCDOTransactions(aFilter)

aMessage = "CDO Transactions Count = " & aCDOTransactions.Count & vbNewLine
for i = 0 to aCDOTransactions.Count - 1
  set aCDOTransaction = aCDOTransactions.Item(i)
  aMessage = aMessage & vbNewLine & (i + 1) & ") " &_
    "Created on: " & aCDOTransaction.CreatedOn & vbNewLine &_
    "     ID: " & aCDOTransaction.ID & vbNewLine &_
    "     CID: " & aCDOTransaction.CID & vbNewLine &_
    "     Pos Code: " & aCDOTransaction.PosCode & vbNewLine &_
    "     Privacy: " & aCDOTransaction.Privacy & vbNewLine &_ 
    "     Recorder: " & aCDOTransaction.Recorder & vbNewLine &_
    "     Privacy PPPU ID: " & aCDOTransaction.PrivacyPPPUID & vbNewLine &_    
    "     Privacy Role ID: " & aCDOTransaction.PrivacyRoleID & vbNewLine
    
  if aCDOTransaction.PrivacyPppuID > 0 then
    set aProv = Profile.LoadProviderById(aCDOTransaction.PrivacyPppuID)
    aMessage = aMessage &_
      "     Privacy Provider: " & aProv.FullName & vbNewLine    
  end if      
  
  if aCDOTransaction.PrivacyRoleID > 0 then
    set aParam = Profile.CreatePrivateRoleLoadParam
    aParam.RoleIdExactly = aCDOTransaction.PrivacyRoleID
    set aRoles = Profile.LoadPrivateRoles(aParam)
    set aRole = aRoles.Item(0) 
    aMessage = aMessage &_
      "     Privacy Role: " & aRole.RoleName & vbNewLine   
   end if  
next    

Profile.MsgBox(aMessage) 
Note:

In Profile Client v8 on User Interface CDO Transaction Privacy Settings can be found in Clinical > Medical Record > Results > Right-click on the transaction > Set Properties > Properties > Privacy field.

Version information

Added in v8.3.0
Access changed to read/write in v8.4.20