Professional OPC
Development Tools

logos

Online Forums

Technical support is provided through Support Forums below. Anybody can view them; you need to Register/Login to our site (see links in upper right corner) in order to Post questions. You do not have to be a licensed user of our product.

Please read Rules for forum posts before reporting your issue or asking a question. OPC Labs team is actively monitoring the forums, and replies as soon as possible. Various technical information can also be found in our Knowledge Base. For your convenience, we have also assembled a Frequently Asked Questions page.

Do not use the Contact page for technical issues.

Catching Exceptions with Read Multiple or Multiple -Operation Methods

More
25 Jun 2024 18:59 #12885 by support
Hello.

The primary method for testing the result is the Exception property in the result objects. If it is non-null, there was an error, and it contains the exception describing the error. The Succeeded property is just a simplified test for "Exception == null|.

I do not quite understand what you are after, i.e. what you precisely mean by "OPC Server goes down". Are you looking exclusively for a situation when the OPC Server performs an orderly shutdown? Or do you want to include other situations as well?

Regards

Please Log in or Create an account to join the conversation.

More
25 Jun 2024 18:30 #12884 by KPersyn33
Hello Team,

I have been working with a customer who is using ReadMultiple and would like to have a catch for when the OPC Server goes down. On the docs it mentions that you should not put try/catch statements or similar constructs around calls to this method. The only exceptions thrown by this method are for usage errors, i.e. when your code violates the usage contract of the method, such as passing in invalid arguments or calling the method when the state of the object does not allow it. Any operation-related errors (i.e. errors that depend on external conditions that your code cannot reliably check) are indicated in the result objects returned by the method.

I was wondering if there was any other way or suggestions for knowing when the OPC Server goes down/or methods for catching those exceptions other than the 'succeeded' call.

Thanks!

Please Log in or Create an account to join the conversation.

Moderators: support
Time to create page: 0.043 seconds