IsError / LastError

Top  Previous  Next

Object: EHL7.EHL7Processor

FileName: EHL7.dll

 

PROPERTY

 

These 2 properties go hand in hand

 

Name: IsError

DataType: Boolean

Mode: Readonly

Description: Returns the error state of the object

 

PROPERTY

 

Name: LastError

DataType: String

Mode: Readonly

Description: Returns the last error message generated by the object.

 

Every time you issue a call to a method or receive an event in the EHL7.EHL7Processor object you can check these two properties.

 

If IsError is True you can display or act on the contents of the LastError Property.

 

Example:

Dim myProcessorObj As New EHL7.EHL7Processor

myProcessorObj.IniFileName = "C:\SomeBadFileName.ini"

If Not myProcessorObj.OpenProfile() Then

       MsgBox myProcessorObj.LastError

       'Would display 'Profile filename does not exist or is not visible at this time'

End If