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.

Application failed with .NET runtime related issue when used in COM mode

More
22 Nov 2017 15:34 #5679 by support
First of all, I have to say that I am not 100% sure if this procedure is going to work. Normally, it should. But I have seen cases in which it did not.

It is relatively simple. The steps (after you install and run Visual Studio) should be:

1. Start your application (I am assuming it is not going to crash quickly and will give you time to do the steps below).
2. In Visual Studio, do Debug -> Attach to Process
3. Press the "Select" button right to the "Attach to:" box.
4. In the "Select Code Type" dialog, select "Debug these code types" radio button, and in the list below, check "Managed (v4.6, v4.5, v4.0)" and "Native".
5. Press OK.
6. In the list of processes (back in the Attch to Process) dialog, select the process of your application.
7. Press "Attach".
8. Wait for your application to crash. Hopefully, at that moment, it will break itself automatically into Visual Studio.
9. Make note/screenshot of what message appears at that moment.
10. Do Debug->Windows->Output, and select "Show output from" = Debug. Select all text (Ctrl+A), then Copy everything to clipboard, and send it to us.
11. Do Debug->Windows->Modules. In the Modules window, select all (Ctrl+A, or through right-click), then Copy everything to clipboard, and send it to us.
12. Do Debug->Windows->Threads. In the Threads window, under the Location column, expand each thread by clicking on the "down arrow". Select all (Ctrl+A, or through right-click), then Copy everything to clipboard, and send it to us. This is the most important piece of information.

Regards

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

  • m.baumgartner
  • Topic Author
  • Visitor
  • Visitor
22 Nov 2017 14:41 #5676 by m.baumgartner
Ok we will try to do that but we have zero knowledge about visual studio.

Would you mind explaining to us the steps to configure it correctly and launch the debugger? Or even assist us in live to set it up?

Thank you.

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

More
22 Nov 2017 14:29 #5674 by support
Hello,

your version are all fine.
I do not know which level of debugger is included in the Visual Studio Express/Community editions. But even if it's not sufficient, I think you can install a full Visual Studio and run it for 30 days for free.

Best regards

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

  • m.baumgartner
  • Topic Author
  • Visitor
  • Visitor
20 Nov 2017 10:53 - 20 Nov 2017 10:54 #5669 by m.baumgartner

1) We're using Windows 10 Creators update
2)


3)

Attachments:
Last edit: 20 Nov 2017 10:54 by m.baumgartner.

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

More
20 Nov 2017 10:43 #5668 by support
This registry part basically shows the version of .NET Runtime and not the .NET Framework (libraries). Since all 4.x versions use the same "original" runtime version 4.0, that's what you see.

To answer this question, there are some tools to do so, or we just need to know
1) the operating system you are using, and
2) which .NET frameworks are listed in the Add/Remove Programs control panel applet of windows.

And, this question remained unanswered:
Which QuickOPC version are you using please?

Thank you

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

  • m.baumgartner
  • Topic Author
  • Visitor
  • Visitor
20 Nov 2017 10:33 #5667 by m.baumgartner
I think you are right. However we have mixed signals regarding our current .NET version.

Here is what our registry says


Attachments:

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

More
17 Nov 2017 17:49 #5666 by support
I am kind of surprised by your .NET Framework version. Our recent versions all require .NET Framework 4.5.2 minimum (and should not even run on earlier versions). See kb.opclabs.com/Versions .

Which QuickOPC version are you using please?

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

  • m.baumgartner
  • Topic Author
  • Visitor
  • Visitor
17 Nov 2017 10:14 #5663 by m.baumgartner

OK, so can you please confirm you are not using OPC DA (in this test) at all?


Yes I confirm. This test is 100% OPC-UA. No OPC-DA involved.

Also, as you can see, we're in .NET framework 4.0. Is that a problem? Should we switch to 4.7?

We don't have Visual studio debugger right now. Is it included in the Express version? If so we could maybe try to set it up but we've never done it.

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

More
16 Nov 2017 20:17 #5662 by support
OK, so can you please confirm you are not using OPC DA (in this test) at all?

Anyway, this is going to be difficult, because not much is known about the exception. 0xc0000005 seems to be "Access violation" error. But, that's not normal in a .NET application - the code is managed, so it cannot normally access an invalid address, with exception of a null reference, but for that there is a different exception. It is more likely that it is related to the COM/.NET interop layer.

I do not know which tools you have at hand. If it were me, I would attached a Visual Studio debugger to the service, specifying it to debug native code AND .NET managed code, let it run, and see if it catches the exception together with call stack - which would then hopefully tell us more.

Regards

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

  • m.baumgartner
  • Topic Author
  • Visitor
  • Visitor
16 Nov 2017 10:22 #5661 by m.baumgartner
Oh and I forgot to mention we are using Delphi as a dev environnement.

Erratum : 14 OPC UA tags are changing, not DA. that's a typo.

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

Moderators: support
Time to create page: 0.120 seconds