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.
WriteValue with Delphi
Can you please obtain and tell me the values of DataType and ValueRank attributes of the node you are trying to write to? Either by writing a program for that, or simply by looking at the node with UaExpert. (in that case, please send a whole screenshot of UaExpert with that node, it may give me even more useful info).
Best regards
Please Log in or Create an account to join the conversation.
The problem occurs when I try to write to my server (A Siemens PLC).
The only difference is that to connect to my server I need the lines:
Then I can connect and read values fine but get this error on writing.
If I use the same settings in UaExpert to connect to the PLC I can write fine.
Please Log in or Create an account to join the conversation.
I installed the current QuickOPC version (2017.2) on a new, otherwise empty computer with Delphi. There is a project with Delphi examples, and it contains the Write examples that are equivalent to your - and it ran well out of the box (it is in the UADocExamples part).
So at this moment I do not know how to help you further.
Can you try the examples that we deliver with QuickOPC, to see whether they work or not?
Regards
Please Log in or Create an account to join the conversation.
Also just tested and I get the same error using Write and WriteMultipleValues.
Please Log in or Create an account to join the conversation.
Have you done the import of type libraries as described here: opclabs.doc-that.com/files/onlinedocs/QuickOpc/Latest/User%2...20Libraries%20to%20Delphi.html , with the actual version you are using? If not, please do so, rebuild your project, and retest.
Best regards
Please Log in or Create an account to join the conversation.
But I get the message "Invalid cast from 'System.String' to 'System.Object[]'"
I have also tried the same to a Decimal value and get an Invalid cast from System.Decimal to
System.Object when trying this.
ReadValue works ok in this way but the WriteValue isn't.
Alex.
Please Log in or Create an account to join the conversation.