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.

Object reference not set to an instance of an object. QuickOPC 2020.3 alpha

More
12 Nov 2020 08:55 #9133 by Andriy
Hello,

Thank you for your assistance,
I'm awaiting approval from the customer to update installation. I'll keep you informed
Regards

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

More
10 Nov 2020 19:47 #9120 by support
Hello,

can you please rebuild and test with 5.59.0-rev23 from nuget.org. In relation to this issue, what we are looking for is the call stack again (the innermost exception being the most important; now, there will likely be two of them, the actual exception thrown will be InvalidOperationException ,with inner exception of type NullReferenceException).

Thank you very much for cooperation.

Note that there were some changes; specifically, the EnableNativeClient and EnableNetApiClient properties are now under InstanceParameters and thus need to be set on each new instance of EasyDAClient separately. See kb.opclabs.com/What%27s_new_in_QuickOPC_2020.3 for more information about the changes.

Best regards

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

More
10 Nov 2020 16:14 #9119 by Andriy
Hello,

You are right, I need nuget packages
Regards

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

More
10 Nov 2020 15:15 #9118 by support
Thank you.

You need the NuGet packages and do not need the standalone installer, is that correct?

Regards

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

More
10 Nov 2020 11:12 #9113 by Andriy
Hello,

Here are the answers to your questions
1. I don't have a reproducible scenario. Unfortunately, this exception happens on customer site
2. I can't debug the application on the customer site
3. Yes, I can use special build of QuickOpc.

Regards

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

More
09 Nov 2020 20:26 #9109 by support
Hello,

the developer was unable to reproduce it, and he was also unable to find the issue by analyzing the code. The problem is that with the way the code is written, the original call stack gets overwritten - it is not the one you could have provided.

Questions:
1. Do you have a reproducible scenario, or hints as to how to "likely" get the error?
2. Can you perhaps reproduce the problem under debugger, with exception settings set so that it breaks the exception when a NullReferenceException is thrown (not just when it is unhandled), and when that happens, capture the call stack for us?
3. If none of the above is possible or gives result, would you be willing to try to reproduce on your side with one more "special" build of QuickOPC, which would have the error handling modified just for this case, to presumably catch the proper information we need (the original call stack etc.)?

Kind regards

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

More
09 Nov 2020 18:31 #9108 by Andriy
Hello,

Do you have any updates?
Regards

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

More
27 Oct 2020 06:36 #9028 by support
Oh, I see - in any new report, you need to explicitly mention the fact that you have been instructed to use the prerelease version - as you did in this post.

I have forwarded the issue to the programmer who worked on this part. Will let you know here when I know more.

Kind regards

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

More
26 Oct 2020 18:00 #9027 by Andriy
Hello,

We got an email confirmation from OPC Labs regarding the use of “alpha” version of QuickOPC 2020.3 in test mode to solve the following problem
www.opclabs.com/forum/reading-writing-subscriptions-property...-blocked-subscribe-unsubscribe

Recently, I found a null-reference exception that causes my application to crash. Could you fix that?

QuickOpc version 5.59.0-rev13
EnableNativeClient: False
System.NullReferenceException: Object reference not set to an instance of an object.
   at OpcLabs.EasyOpc.Implementation.NetApi.DataAccess.NetApiEasyDAClient.CheckException(Exception exception, Boolean isOtherMethod)
   at OpcLabs.EasyOpc.Implementation.NetApi.DataAccess.NetApiSubscription.RemoveItemsFromOneSubscription(NetApiOpcDaSubscription subscription, IList`1 itemsToRemove, Boolean freeHandleForSucceeded, NetApiCacheEventArgs cacheEventsArgs)
   at OpcLabs.EasyOpc.Implementation.NetApi.DataAccess.NetApiSubscription.RemoveItems(IList`1 itemsToRemove)
   at OpcLabs.EasyOpc.Implementation.NetApi.DataAccess.NetApiSubscription.RemoveItemsL1(IEnumerable`1 handles)
   at OpcLabs.EasyOpc.Implementation.NetApi.DataAccess.NetApiSubscription.OnTimer(Object state)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   at System.Threading.TimerQueueTimer.CallCallback()
   at System.Threading.TimerQueueTimer.Fire()
   at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
   at System.Threading.ThreadPoolWorkQueue.Dispatch()
the call stack is slightly different
System.NullReferenceException: Object reference not set to an instance of an object.
   at OpcLabs.EasyOpc.Implementation.NetApi.DataAccess.NetApiEasyDAClient.CheckException(Exception exception, Boolean isOtherMethod)
   at OpcLabs.EasyOpc.Implementation.NetApi.DataAccess.NetApiSubscription.RemoveItemsFromOneSubscription(NetApiOpcDaSubscription subscription, IList`1 itemsToRemove, Boolean freeHandleForSucceeded, NetApiCacheEventArgs cacheEventsArgs)
   at OpcLabs.EasyOpc.Implementation.NetApi.DataAccess.NetApiSubscription.RemoveItems(IList`1 itemsToRemove)
   at OpcLabs.EasyOpc.Implementation.NetApi.DataAccess.NetApiSubscription.RemoveItemsL1(IEnumerable`1 handles)
   at OpcLabs.EasyOpc.Implementation.NetApi.DataAccess.NetApiSubscription.OnTimer(Object state)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   at System.Threading.TimerQueueTimer.CallCallback()
   at System.Threading.TimerQueueTimer.Fire()
   at System.Threading.TimerQueue.FireNextTimers()
Regards

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

Moderators: support
Time to create page: 0.072 seconds