ISMedOrderItem.Medication

Description

The medication ordered to the patient.

Syntax

object.Medication

Part Attribute Type Description
object Required
The object always implements the ISMedOrderItem interface
Restriction: This property is readonly.

Return Value

ISRxMedication

Example

Display the number of the medication order items and some information about them.

Dim aPatient
Dim aFilter
Dim aMedOrderItems, aMedOrderItem
Dim aMessage
Dim i  

Set aFilter = Profile.MakeMedOrderItemsFilter
aFilter.ProviderID = Profile.LoadProvider("MM").ID
aFilter.OnlyPNRIrregular = False 
aFilter.OnlyRegular = False
aFilter.OnlyDiscontinued = False

set aMedOrderItems = Profile.LoadMedOrderItems(aFilter)

aMessage = "Medication Order Items Count = " & aMedOrderItems.Count

for i = 0 to aMedOrderItems.Count - 1
  set aMedOrderItem = aMedOrderItems.Item(i)
  set aPatient = Profile.LoadPatient(aMedOrderItem.PatientId) 
  aMessage = aMessage & vbNewLine & (i + 1) & ") " &_
    "Medication Name: " & aMedOrderItem.Medication.RxName & vbNewLine &_
    "Date: " & aMedOrderItem.Medication.Date & vbNewLine &_
    "Patient: " & aPatient.SurnameFirstName & vbNewLine &_
    "URL: " & aMedOrderItem.URL & vbNewLine       
next 

Profile.MsgBox(aMessage)  
Note:

In Profile Client v8 on User Interface Medications can be found in Clinical > Medical Record > MedChart.

Version information

Added in v7.10.90
return type changed from ISPrescription to ISRxMedication in v7.10.90