From 04:00 PM CDT – 08:00 PM CDT (09:00 PM UTC – 01:00 AM UTC) Tuesday, April 16, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Auto Login via TestStand UserInterfaces

Solved!
Go to solution

Hello everybody,

i´m trying to login a user programmatically during the MainForm_load of the Simple Userinterface.

I tried already
axApplicationMgr.GetEngine.CurrentUser = axApplicationMgr.GetEngine.GetUser(current_user)

but this only changes the user which appear in the login window.

Is it possible to start the login process without showing those login window?

Thanks for advice.

0 Kudos
Message 1 of 6
(1,652 Views)

The login prompt is handled by the FrontEndCallBacks sequence.  You can change the behavior by following this article

Automatically Logging In all Users as Operators in Your TestStand Operator Interface - National Inst...

 

0 Kudos
Message 2 of 6
(1,619 Views)

You can also use this method if it suits your application ;

https://forums.ni.com/t5/Example-Code/Automatically-Create-a-TestStand-User-for-the-Windows-System/t...

 

Ravi

0 Kudos
Message 3 of 6
(1,605 Views)

Thank you, ee-jallen, for the link for the article. This solution is not exact what i was looking for but i will try to modifie it to login a specified user.

If i am able to find a solution, i will post it here later.

0 Kudos
Message 4 of 6
(1,594 Views)

Thank you for your advice RaviShrigiri, but our TestSystem will only have one Windows Account for all the user, so this solution don´t work for me.

0 Kudos
Message 5 of 6
(1,586 Views)
Solution
Accepted by topic author sneb898

Okay... The problem was caused, because the EXE-Call parameters were processed after the MainForm_Load, so my current_user variable was still empty.

I set the
axApplicationMgr.GetEngine.CurrentUser = axApplicationMgr.GetEngine.GetUser(current_user)
now in the axApplicationMgr_ProcessUserCommandLineArguments(...) function and it works.

Thanks for your help.

0 Kudos
Message 6 of 6
(1,576 Views)