Validate()

Top  Previous  Next

Object: EHL7.EHL7Processor

FileName: EHL7.dll

 

METHOD

 

Name: Validate()

Parameters: None

Returns: Boolean

Description: Evaluates all property settings of the object and returns a boolean indicating whether the profile can be executed using the ProcessProfile() method. 

 

*Note* This method is actually called inside the object during the ProcessProfile() method so it is not necessary to call this method prior to calling ProcessProfile().  It is useful if you are creating a user interface for users to enter profile settings to verify that all properties have been entered correctly.

 

Example:

'Declare the object

Private WithEvents myProcessorObj As EHL7.EHL7Processor

 

Private Sub Form_Load()

'Instantiate the object

Set myProcessorObj = New EHL7.EHL7Processor

myProcessorObj.IniFileName = "C:\EasyHL7\MyProfile.ini"

If Not myProcessorObj.Validate() Then

       MsgBox "The profile is not valid because: " & myProcessorObj.LastError

       myProcessorObj.ClearErrors

End If

End Sub