This function adds a new registry key to the Rx medication.
object.AddRegistryKey(aKeyCode, aKeyValue)
Part | Attribute | Type | Description |
---|---|---|---|
object |
Required | The object always implements the
ISRxMedication interface |
|
aKeyCode |
In, Required | string |
The code of the registry key |
aKeyValue |
In, Required | string |
The value of the registry key |
Add a new registry key with the specified code and value to the Rx medication.
Dim aRxMedication
Dim aList
Dim aKeyCode, aKeyValue
Dim aRegistryKey
Dim aRxMedicationInfo
Set aRxMedication = Profile.LoadRxMedication(1507)
if aRxMedication is nothing then
Profile.MsgBox("There is no Rx Medication with the specified ID")
exit sub
else
set aList = aRxMedication.GetRegistryKeys
aKeyCode = "CODE1"
aKeyValue = "Code1"
set aRegistryKey = aRxMedication.AddRegistryKey(aKeyCode, aKeyValue)
if not aRegistryKey is nothing then
aRxMedicationInfo = aMessage & vbNewLine & "New Registry Key with code '" &_
aKeyCode & "' was added successfully " &_
"(Id= " & aRegistryKey.Id & ", Key Value = " & aRegistryKey.KeyValue & ")"
else
aRxMedicationInfo = "There is no Registry Key with the specified code"
end if
end if
Profile.MsgBox(aRxMedicationInfo)
In Profile Client v8 on User Interface Registry Key cannot be found, but the possible codes of Registry Keys can be found in
.