godsharp / opcsample

Opc Sample
https://godsharp.github.io/opcsample/
35 stars 14 forks source link

System.Runtime.InteropServices.COMException #4

Closed avnet78 closed 1 year ago

avnet78 commented 2 years ago

I am following the code provided in the opcsample/Program.cs and I am getting the below exception. Should I register any of the com dll's using regsvr? Please advise.

System.Runtime.InteropServices.COMException: 'Retrieving the COM class factory for component with CLSID {28E68F9A-8D75-11D1-8DC3-3C302A000000} failed due to the following error: 80040154 Class not registered (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG)).'

These are the dll's inside the bin folder:

image

aevi1103 commented 2 years ago

@avnet78 have you fixed this error I have this error too

avnet78 commented 2 years ago

No, I tried but could not fix it and that’s when I created the issue.


From: Aevi @.> Sent: Tuesday, August 9, 2022 6:39:21 PM To: godsharp/opcsample @.> Cc: AVNet @.>; Mention @.> Subject: Re: [godsharp/opcsample] System.Runtime.InteropServices.COMException (Issue #4)

@avnet78https://github.com/avnet78 have you fixed this error I have this error too

— Reply to this email directly, view it on GitHubhttps://github.com/godsharp/opcsample/issues/4#issuecomment-1209996394, or unsubscribehttps://github.com/notifications/unsubscribe-auth/APBE5DFIULE2IKT4VHXN5EDVYLT2TANCNFSM555WSIKA. You are receiving this because you were mentioned.Message ID: @.***>

seayxu commented 2 years ago

@aevi1103 @avnet78 If you want to use OpcAutomation or Graybox, you should register dll, and this is only support x86. If you want to support x64, you should use OpcNetApi and install OPC Core Components. Opc Da Introduction