LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Error 1172 occurred at Invoke Node

What makes this a mistake, how can I fix it?
Last week it was still good!

 

Error:

Error 1172 occurred  at Invoke Node System.Reflaction.TargetInvocationException

Inner Exception:

System.InvaidOperationException

Download All
0 Kudos
Message 1 of 3
(3,577 Views)

That is the general .NET exception handler error code wrapper. Unfortunately I don't understand the error message in your native tongue. Would you be able to translate this? Either way the error indicates that an exception occurred trying to perform that Invoke node call - it looks like you are trying to make a call into the Windows Presentation Foundation framework (see here). Most likely the exception is thrown since the UI loop is controlled through LabVIEW and not the framework (ie see "STA" mentioned there, most likely indicating a different threading apartment model then LabVIEW).

There are other ways to achieve this in LabVIEW - you can use an event structure to monitor for a key press and then determine if it is the key you wanted (or some other).

0 Kudos
Message 2 of 3
(3,523 Views)

I was able to reproduce your error on my machine. It is complaining about STA (Single-threaded Apartment) since there are other UI resources competing for your key-press events.

 

Why not monitor key-presses via Event structure?


Kudos are the best way to say thanks 🙂
Message 3 of 3
(3,521 Views)