SetComponentValue - HL7 Module - Foundation 23.1 - Foundation 23.1 - Ready - OnBase - Essential - Premier - Standard - external - Premier - Standard - Essential

HL7 Module

Platform
OnBase
Product
HL7 Module
Release
Foundation 23.1
License
Premier
Standard
Essential

This method is used to set the value of a specific component to a different value.

blnSetComponent = objHL7Field.SetComponentValue(1, "New Component Value")

Parameter

Type

Description

Component #

Integer

0 to (max-1), where max is from GetNumComponents.

Value string

String

Replacement value for this component.

Return Value

Description

0

Returned if the value could not be changed. For example, perhaps the input integer is less than 0 or greater than the number of components in the field.

If the number of components in the field is 0, then it is a special case, and SetValue will be used.

1

Returned if the input integer is within the range of components in the field (between 0 and the max number of components). If the original value and the new value exactly match (meaning the data did not change), then the return value will still be 1.