Professional OPC
Development Tools

logos

Reading and Writing from vba (Access 2016) to RSLinx Gateway

More
21 Jun 2020 09:27 #8619 by support
Most likely, "Class not licensed for use" is not coming from QuickOPC and is not referring to QuickOPC license.
I have seen it with RSLinx quite commonly.

What can be happening is that RSLinx thinks you are using it in an unlicensed way (remotely). IIRC, RSLinx OPC server is implemented "in-process", in a 32-bit DLL. And they expect the OPC client be a local 32-bit application. If they detect they are are running in a "wrapper" process, which happens when a remote client accesses the server over DCOM, they return the "class not licensed" error.

Unfortunately, the wrapper process is also used when the OPC client is a local 64-bit app. In such case RSLinx thinks the client is remote, and complains about the license as well.

I suppose you are running 64-bit Access. A workaround might be to use 32-bit Access.

I have also received your post over our Contact form. Do not purchase QuickOPC until you get it running with the trial license. I do not want to find ourselves in the situation when it still won't work then. The problems you are having have nothing to do with QuickOPC licensing.

We have recently seen some issues on computers that do not have Visual Studio installed, which is your case I suppose as well. To make sure this is not the problem, can you please do the following:

1. Visit support.microsoft.com/en-us/help/2977003/the-latest-supported-visual-c-downloads .
2. Scroll down to find the heading "Visual Studio 2015, 2017 and 2019".
3. In that paragraph, if you are on 32-bit machine, download and install x86: vc_redist.x86.exe . If you are on a 64-bit machine, install the previous as well, and *also* download and install x64: vc_redist.x64.exe .

And the re-run your tests.

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

More
20 Jun 2020 17:02 #8618 by jwomacks
With digging a little further I am finding out that the exception is a Class not licensed for use. I feel if I buy the license , everything will work perfectly. I am going to use this software in my project that I am distributing. just let me know what SDK package I need to purchase. I am also going to play with using this in .NET and with C#

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

More
20 Jun 2020 16:39 #8617 by jwomacks
Something very interesting. When I run the Connectivity Explorer I get the same runtime exceptions error. also I received the following error. I think it is something with the .Net
Attachments:

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

More
20 Jun 2020 16:21 #8616 by jwomacks
even without changing to read from rslinx I am getting it when I run either the read or write methods.

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

More
20 Jun 2020 15:35 #8615 by support
Hello.
Some questions:

1. When you step to the code (using debugger), does the error happen on the "Dim Client As... " line, or on the line with ReadItemValue ?

2. Does the error happen only with the ReadCommandButton (which uses RSLinx), or also with the WriteCommandButton (which uses our simulation server)?

Thank you

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

More
20 Jun 2020 15:23 #8614 by jwomacks
I ran your demo application and was able to get the item id along with the qualified name of the rslinx server. I matched the code and receivet the runtime error...i must be close...thanks for your help
Attachments:

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

More
20 Jun 2020 14:54 #8613 by support
Your code is fine.

You need to figure out the OPC ItemID. In order to get an idea of what Items exist in the server and what are their IDs, run Tools -> Connectivity Explorer from the QuickOPC Launcher app, and navigate to the RSLinx server and expand it.

QuickOPC support OPC Classic as well as OPC UA. Both have their pluses and minuses. If the RSLinx supports both too (I am not sure), then the choice is yours. Otherwise, you need to pick the one for the client side to match the server side.

Best regards

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

More
20 Jun 2020 14:50 #8612 by support
To the proxy registration error:

You may have to download and install OPC Core Components, from opcfoundation.org/developer-tools/samples-and-tools-classic/core-components/

Best regards

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

More
20 Jun 2020 14:39 #8611 by jwomacks
I have been able to get rslinx fully licensed. none of the examples have a qualified example of how you connect to a tag in a Rockwell logix plc. Should I be using the UA dll or the Classic dll…. I may not be able to use this SDK.

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

More
20 Jun 2020 11:59 #8610 by jwomacks
Attachments:

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

Moderators: support
Time to create page: 0.302 seconds

      

 Recommend this on Google