Open Shrimpis opened 2 years ago
Hope this solution can help, cheers!
This is not a solution - you are referring to a completely separate project built with a different technology stack. It is, at best, an alternative approach.
@Shrimpis You likely don't have the right URI defined for the server. I was getting this error when I just referred to the remote IP of my OPC DA server. Updating the format to the below worked though:
The format of the URL is: “opcda://{PCName or IP Address}/{ProgID of OPCDA}”
Specifically, I used this format:
Uri url = UrlBuilder.Build("28272A37-5BF6-4F16-B300-331EE07880FD", "192.168.1.13");
using (var server = new OpcDaServer(url))
{
server.Connect();
...
}
(from https://community.dataparcsolutions.com/manual/index.html#!Documents/opcdasourceconfiguration.htm)
Hope this solution can help, cheers!
This is not a solution - you are referring to a completely separate project built with a different technology stack. It is, at best, an alternative approach.
Depends on how you define a solution. If it is as simple as using .NET to retrieve DA data back - yes, it is a similar solution. From this point it is a better and simpler solution - without heavyweight OPC SDK, no worry about DCOM, and internet accessible. As a .NET client application, user shouldn't worry about different technology stack once it can assist him to use .NET to get job done. Just my 2 cents.
Hello,
I am getting the following error when trying to connect the my opc server with a DA client: System.Runtime.InteropServices.ExternalException (0x80040154): CoCreateInstanceEx: Class not registered at TitaniumAS.Opc.Client.Interop.System.Com.CreateInstance(Guid clsid, String host, NetworkCredential credential) at TitaniumAS.Opc.Client.Interop.System.Com.CreateInstanceWithBlanket(Guid clsid, String host, NetworkCredential credential, ComProxyBlanket comProx)...
This is how my class looks like which handles the connection and browsing: `public class OPCDAClient { private OpcDaServer Server = null; private OPCClientSettings Settings; private List Listeners = new List();
Any help regarding this would be awesome!