ISOrderItem.GetContactActionLink

Description

This function returns the contact action linked to the order.

Syntax

object.GetContactActionLink()

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

Return Value

ISContactLink

Returns the contact action linked to the order.

Example

Display the number of the orders and some information about the order items, including the contact actions linked to the orders.

Dim aPatient
Dim aOrdersLoader
Dim aOrders, aOrder
Dim aOrderItems, aOrderItem
Dim i, j
Dim aMessage

Set aPatient = Profile.SelectPatient
set aOrdersLoader = Profile.CreateOrdersLoader
aOrdersLoader.Patient = aPatient
aOrdersLoader.ChangedSince = #01/01/2000#

set aOrders = aOrdersLoader.LoadOrders

aMessage = "Orders Count = " & aOrders.Count & vbNewLine

for i = 0 to aOrders.Count - 1
  set aOrder = aOrders.Item(i)
  aMessage = aMessage & vbNewLine & (i + 1) & ") " &_
    "Order: " & aOrder.GetDTModified & vbNewLine
  
  set aOrderItems = aOrder.OrderItems   
  for j = 0 to aOrderItems.Count - 1
    set aOrderItem = aOrderItems.Item(j)
    aMessage = aMessage & (i + 1) & "." & (j + 1) & " " &_
      "-Order Item Creation Date: " & aOrderItem.CreationDate & vbNewLine &_
      "      -Ad Hoc Text: " & aOrderItem.AdHocText & vbNewLine &_
      "      -Additional Info: " & aOrderItem.AdditionalInfo & vbNewLine &_
      "      -Instructions: " & aOrderItem.Instructions & vbNewLine &_
      "      -Investigation Ref: " & aOrderItem.InvestigationRef.Name & vbNewLine
    
    if not aOrderItem.GetContactActionLink is nothing then  
      aMessage = aMessage & "      -Get Contact Action Link: " &_
        aOrderItem.GetContactActionLink.Description & vbNewLine
    end if   
     
  next 'j    
next 'i    

Profile.MsgBox(aMessage)    
Note:

In Profile Client v8 on User Interface Contact Action can be found in Clinical > Medical Record > Past Orders > Select the order > Edit the related encounter > New Encounter > Contact Actions.

Version information

Added in v8.5.0