10-31-2019 11:33 AM
I have one Main VI in with i am creating and generating the user event. This VI launch a reentrant VI. Then I launch multiple threads of the reentrant VI from the Main VI. Then I am sending the user event to the Reentrant VI, always the latest instance of the reentrant VI is getting that user event but not the other. Can someone suggest what might be going on wrong.
Solved! Go to Solution.
10-31-2019 11:46 AM
Need to see code. The current thoughts I am having is you have something destroying your User Event each time you launch or you are passing in the registration (you need to pass in the User Event and then each instance registers for that event).
10-31-2019 11:47 AM
It would help if you posted some code.
10-31-2019 11:59 AM
Thank you for your swift response.
I have attached the code files for reference.
10-31-2019 12:15 PM
Since you didn't include the Main vi it's hard to know. The vi that you attached is set to non-reentrant, which is different than what you stated. This looks like an Action Engine and will only work if it is non-reentrant.
10-31-2019 01:52 PM - edited 10-31-2019 01:52 PM
Hey, my first guess was almost correct. You are creating a new User Event with each "registration". Your "Create User Event" case in your Action Engine should first check to see if the current reference is valid (use Not A Number/Path/Refnum). If it is valid, just pass that reference out. If not valid, create the User Event like you already are doing.
10-31-2019 03:37 PM
Thank you for the solution. It worked perfect