ISCareVisit.getAction

Description

This function returns the actions of the intervention template by their code.

Syntax

object.getAction(Code)

Part Attribute Type Description
object Required
The object always implements the ISCareVisit interface
Code In, Required
string
The code of the action

Return Value

ISCareAction

Returns the actions of the intervention template by their code.

Example

Display the actions of the intervention template by their code.

Dim aCarePlan
Dim aMessage
Dim aVisits
Dim aVisit
Dim aSelectedAction

Set aCarePlan = Profile.LoadCarePlanByCode ("FLU") 
set aVisits = aCarePlan.Visits

if aVisits.Count = 0 then
  Profile.MsgBox("There are no care visits!")
  exit sub
end if  
 
for i = 0 to aVisits.Count - 1
  set aVisit = aVisits.Item(i)
  aMessage = aMessage & vbNewLine &_
    "Intervention: " & aVisit.Description 

  set aSelectedAction = aVisit.getAction("FLUVAX") 
  
  if aSelectedAction is Nothing then
    aMessage = aMessage & vbNewLine &  "  No action with the code"     
  else
    aMessage = aMessage & vbNewLine &  "  Action: " & aSelectedAction.Description      
  end if  

next 'i
  
Profile.MsgBox (aMessage)
Note:

In Profile Client v8 on User Interface Action can be found in Maintain > Care Plans > Open Plan > Inteventions.

Version information

Added in v7.8.0