NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

How To change Station Id Value in Teststand

Solved!
Go to solution

Hello, 

I am new to Testsand. by reading some chats I have convert the "Station Id"  to "Project ID". As you can see it in below attachment figure 1. Now, I want to change the Value of it. As of now I change it manually, as shown in below figure 2 . So I want to change it for each sequence. When I run the sequence, It will automatically get the value from the globle variable and add it in to the report in the front of Project Id.  Can someone help me do that. or if someone has better idea than mein, Please guide me 

Download All
0 Kudos
Message 1 of 9
(97 Views)

During Runtime, you have access via 

RunState.Root.Locals.StationInfo.StationID



Use an ExpressionStep to assign a value.

 

Having said that: having to assign this in every sequence file is not maintainable code

0 Kudos
Message 2 of 9
(89 Views)

Hi, 

Thank you for the reply, This same Expression I have already used in my code but I got an error "unknown Variable or Property name".

Is there any alternative idea, I just want to add project name in to the Header section of the Report 

0 Kudos
Message 3 of 9
(72 Views)

Oli_Wachno_0-1738846583458.png

Works on my machine as long as you run vi SinglePass or Test UUTs

0 Kudos
Message 4 of 9
(61 Views)

Rshah31_0-1738847402858.png

I can not understand this things. Still I am getting error. Expression is exactly  same . 

Are you writting it in the Main Seq. or PreUUT or else? 

0 Kudos
Message 5 of 9
(57 Views)

Yes, from MainSequence.

Which is the location you'd like to access this from?

0 Kudos
Message 6 of 9
(54 Views)

I could not get your question. I am also writing in the main sequence. 

Basically, I can find Runstate.Root , however, could not find stationInfo in the Variables. 

Please check below figure 3 

0 Kudos
Message 7 of 9
(27 Views)
Solution
Accepted by topic author Rshah31

RunState.Root is an object that gets populated during run-time

You need to suspend the execution in order to see it

 

My screenshot referes to a suspended execution

0 Kudos
Message 8 of 9
(18 Views)

Yes, I got the solution

Thank you for the support

Best regards, 
RS

0 Kudos
Message 9 of 9
(15 Views)