WEBfactory 2010

Beckhoff ADS Interface Error Codes

Abstract

Check out this article and learn more details about the WEBfactory 2010 Beckhoff ADS Interface error codes.

Method

Error Code

STDMETHODIMP CWFClient::Init(BSTR configXML, VARIANT* signalNames, VARIANT* dataTypes, LONG startCommunication, LONG* returnValue)

  • -999 = Invalid license

  • -1 = Error opening configuration XML parser

  • -2 = Error parsing XML configuration

  • -3 = Invalid XML configuration, despite the fact that it is correctly formatted XML string

  • -4 = Failure to build list of signals out of XML configuration

  • 0 = Success

STDMETHODIMP CWFClient::Reset(LONG* returnValue)

  • 0 = Success

STDMETHODIMP CWFClient::DefineSignal(BSTR signalName, BSTR furtherDefinition, LONG* dataType, LONG* returnValue)

  • -1 = The only return code for all possible scenarios, because actually DefineSignal is not implemented function

STDMETHODIMP CWFClient::ActivateSignals(VARIANT signalNames, VARIANT statusFlags, VARIANT* results, LONG* returnValue)

  • -99 = Connector was not initialized

  • -11 = Wrong signalNames parameter data type

  • -12 = Wrong statusFlags parameter data type

  • -1 = Wrong signalNames parameter, cannot be converted to strings

  • -2 = Wrong statusFlags parameter, cannot be converted to integers

  • -3 = Number of signals and status flags does not match

  • -4 = Number of signals to activate is zero

  • -5 = Signal activation fails as a whole

  • 0 = Success

Results parameter

  • 1 = License quota insufficient to allow signal activation

  • -1 = Attempt to activate nonexistent signal

  • 0 = Success

STDMETHODIMP CWFClient::WriteSignalsAsync(VARIANT signalNames, VARIANT signalValues, VARIANT* results, BSTR* guidAsync, LONG* returnValue)

  • -99 = Connector was not initialized

  • -11 = Wrong signalNames parameter data type

  • -12 = Wrong signalValues parameter data type

  • -1 = Wrong signalNames parameter, cannot be converted to strings

  • -2 = Wrong statusFlags parameter, cannot be converted to variants

  • -21 = Number of signals and values does not match

  • -24 = Number of signals to write to is zero

  • -5 = There are no signals which could be written to, because each signal had some issue: signal name was not found, or there was failure to convert value to write to correct datatype

  • 0 = Success

Results parameter

  • -1 = Signal with given name was not found

  • -22 = Attempt to convert value, which should be written, from vb6 data type

  • -2 = Attempt to convert value, which should be written, to correct data type

  • 0 = Write will be attempted

From asynchronous completion by OnWriteSignals result

  • -1 = Writing to inactive signal

  • -2 = Handle for signal is invalid. That means that hardware device does not recognize the signal name, or we do not have communication access to the device

  • -4 = Error writing signal value to device, writing failed for whole group of signals being written

  • -6 = Error writing signal value to device, writing failed individually

  • 0 = Success

STDMETHODIMP CWFClient::WriteSignalsSync(VARIANT signalNames, VARIANT signalValues, VARIANT* results, LONG* returnValue)

  • -99 = Connector was not initialized

  • -11 = Wrong signalNames parameter data type

  • -12 = Wrong signalValues parameter data type

  • -1 = Wrong signalNames parameter, cannot be converted to strings

  • -2 = Wrong statusFlags parameter, cannot be converted to variants

  • -21 = Number of signals and values does not match

  • -24 = Number of signals to write to is zero

  • -5 = There are no signals which could be written to, because each signal had some issue: signal name was not found, or there was failure to convert value to write to correct datatype

  • 0 = Success

Results parameter

  • -1 = Signal with given name was not found, or writing to inactive signal

  • -22 = Attempt failed to convert value, which should be written, from vb6 data type

  • -2 = Attempt failed to convert value, which should be written, to correct data type. Or handle for signal is invalid. That means that hardware device does not recognize the signal name, or we do not have communication access to the device

  • -4 = Error writing signal value to device, writing failed for whole group of signals being written

  • -6 = Error writing signal value to device, writing failed individually

  • 0 = Success