NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

TestStand Logout Closes Sequence File

Solved!
Go to solution

Hello Community,

 

I am using TestStand 2016 32-bit & Labview 2016 32-bit

I am working with the TestStand Simple UI in Labview.

 

I want the user who is logging in to use the same sequence file that the previous user who logged out was using and not have to reload the sequence file again. Before I only had the login/logout button set to login, so the sequence file never closed. However, to prevent a user from using another users name I need the GUI to logout.

 

Is there a way to not close the sequence file when a user logs out?

 

Thank you

 

0 Kudos
Message 1 of 7
(3,181 Views)

Does it maybe have to do with altering the FrontEndCallbacks sequence file?

0 Kudos
Message 2 of 7
(3,165 Views)

Logging out in TestStand always closes all sequences, even in the Sequence Editor.  

 

I would suggest that when a user opens a sequence file, that path is saved to a file somewhere.  Then, when you see a new login, you can get that path and use the attached code to open it in your UI.

 

Pulido Technologies LLC

Message 3 of 7
(3,155 Views)

I am having an issue with tracking the user name. When I test to see if the LoginName is empty or not, it is not accurate with current results. This is because the login/logout dialog pops up after "DoClick", but the LoginName code executes before a user can login. So when I click to Login, it is showing the previous value which could be empty or another user and not the current user.

 

What is the best way to track the user login?

 

The reason for tracking the user, because I am trying to only reload the sequence file if a user logged in. I don't want to open the sequence file if the user selected cancel or logged out.

0 Kudos
Message 4 of 7
(3,145 Views)
Solution
Accepted by topic author MechUnit

Initially, when starting my UI, I register an event linked to "User Changed".  When that event occurs, I generate a user event.  Then, in my main loop, I handle the User Changes event.  That's where you can check if there's a user logged in and then do whatever else needs to happen when the  user changes.

 

Pulido Technologies LLC

Message 5 of 7
(3,136 Views)

I gave what you suggested a try and I am almost to the finish line.

I ran into one additional issue with "Event Reg Refnum" that I could use your help on please.

How do you handle multiple events and get them both to show up in the event structure?

See picture attachments.

Thank you

Download All
0 Kudos
Message 6 of 7
(3,108 Views)

I believe the issue with wiring Reg Events to Event Reg Refnum is that the type def cluster has a "different" Event Reg Refnum". You should create a new one from the Reg Events and put that in your type def cluster; this new one will have both of your events for quit application and user change.  That should also solve your issue with how you don't see the user change event in your event structure.

 

Pulido Technologies LLC

 

 

0 Kudos
Message 7 of 7
(3,105 Views)