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.

Serialize UAGenericObject as JSON

More
11 Nov 2019 13:39 #7954 by jlorek
Thanks for the info.

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

More
05 Nov 2019 06:28 #7912 by support
Unfortunately we do not currently have JSON serialization for UAGenericObject (or any our objects, in fact). I suggest that you design something of your own.

I would also slightly recommend against using the XML format for any long-term storage, because there was a consideration to change it in some future version (although no plans have been made yet). While we will probably provide some means for conversions, there will be an extra effort at that point.

Best regards
The following user(s) said Thank You: jlorek

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

More
04 Nov 2019 15:44 #7909 by jlorek
Hi,

after successfully reading data as OpcUa Complex Data i need to serialize the data in JSON format to store the measurement in a NoSQL database.
I already figured out how to serialize the data in XML format, but i was surprised that besides the actual data, the serialized XML contains tons of namespace information and type definitions. The desired JSON structure i hope to achive should be very close to the Debug Output created by UAGenericObject.ToString("V"), which just contains name and actual values.

Is there alreay a built-in mechanism to serialize a UAGenericObject (or any other data object) to JSON?

Thanks,
Jens

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

Moderators: support
Time to create page: 0.042 seconds