I had a perfectly performing program that communicates with the H4 ECOM via some programming I borrowed with the original owners permission. Something has changed and I do not know how to handle the problem. It is a Visual Basic program developed in Visual Studio to communicate with and record the status of a board wash system which has the H4 ECOM in it. The command:
Rc = HEIQueryDevices(pTransportStructure, aDevices, DeviceCount, HEIAPIVersion)
Returns a code for RC =10022
Dim pTransportStructure As IntPtr 'pointer to HEITransport structure this structure will be located in the unmanaged heap
pTransportStructure = Marshal.AllocHGlobal(Marshal.SizeOf(TP))
DeviceCount = MAXDEVICES
MAXDEVICES = 100
HEIAPIVersion = 3
What does this error code mean? Is there is list of response codes that I can have to add to my code in the case of errors or any other response than 0 which the code is looking for.
If Rc <> 0 Then
DisplayList.Items.Add(String.Format("Error {0} trying to query network", Hex(Rc)))
Else
If DeviceCount = 1 Then
DisplayList.Items.Add(String.Format("Found{0} device", Str(DeviceCount)))
Else
DisplayList.Items.Add(String.Format("Found{0} devices", Str(DeviceCount)))
End If
If DeviceCount > 0 Then
Your help in this matter is greatly appreciated.
Thank you,
Toruk