NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

SequenceFilePostStepFailure

Thank you,

But that's not exactly that what i want. But it is help full. Can you give me some tips what i have to do that it runs in this way.

I want it in this way. If an Error occurs my ErrorHandler.seq will be open. Then comes the message pop up with five buttons. The new button named ErrorConfig. This i have done. In the Message Pop is in the last row a sentence like Error: and then the Error Text.

If in the variable Locals.Error no text inside i pressed the button ErrorConfig. Then a window open and i can enter an Text. This text will be saved in the Locals.Error variable. If an error in this step occurs again in the Message Pop in the Last row behind Error: the text will be shown.

How can i realise this?

I have made an fithed Button in the Message Pop in the ErrorHandler.seq. Then i had insert in the Message Expression this. +"Error:" + RunState.Caller.Locals.Error. But with this Locals variable i get back an error.

In the ErrorHandler.seq i have insert an SequenceCall named ErrorConfig. If i pressed the Button errorconfig in the Message Pop up this Sequence this sequence will be called then your example will be performed.

What i have to do that it works like discribed above?

Thank you for your help an thas no problem for the late response. You don't need to change my Example it would to be enough if you gave me some fingerpost how i came to my finish.

Thank you very much again.
0 Kudos
Message 21 of 49
(1,839 Views)
Now i have made an LabView Vi i can enter an String. This vi i have changed with the selector Message Pop up. the view error selector show my entered string.
But i have insert the Locals.Error in the Message Pop up in the ErrorHandler.seq and then i had an Error that this variable Locals.Error don't exist.

That right because this variable will creat after i had pressed the ErrorConfig Button and your Example had finished. What can i do that the error message will shown in this MEssage Pop Up in ErrorHandler.seq.

The full error:

DetailS: Erro Evaluating Message Expression: Unknown variable or property name 'Locals.Error'

Error Code: -173056; Unknown variable or property name.

Location: Step 'Message Popup' of sequence 'MainSequence' in 'ErrorHandler.seq'
0 Kudos
Message 22 of 49
(1,834 Views)
Hi,

You can not use the expression to write to your Locals.Error if it doesn't exist, you will have to create it first using a TS API call.

In my example I used a TS API call PropertyObject.SetValString with one of the methods parameters (Options) set to 1. This means if the property doesn't exist it will create it, then set it value to the new value you require.

Seeing as you have made a VI to enter your string, you might as well do the extra.

That is:
//Set initial value
If PropertyExists("Locals.Error")
If Locals.Error != ""
set your string control on your VI front panel with the contents of Locals.Error

//enter user input
Loop while waiting for input.

// exit from user input loop set Locals.Error
PropertyObject.SetValString("Locals.Error", 0x1, )



Regards
Ray Farmer
Regards
Ray Farmer
0 Kudos
Message 23 of 49
(1,833 Views)
Is it possible to create a variablen Locals.Error in the Displaytest3.seq at the step Zufallszahl.vi durable and not only for the copy of the sequence in runtime?

Because i had made my vi with a stationglobal so the text i wrote with the vi in the variable stationglobal.error i wrote in the activex like this.

"Error" + str(StationGlobal.Error) Now in my Message Popup i get shown the error but he is for every error step the same and that is not what i want.

And my colleague want it like this:

Is variable exist no? generating variable
Is variable exist Yes? Errortext shown
Errortext change if needed
Errortext wrote in variable.

What is the diffrent between FileGlobals, StationGlobals and ThisContext.FileGlobals ,StationGlobals and the FileGlobals and StationGlobals in RunState.ThisContext. Where can i get some documentaion about the Expression and his functions or the diffrents between RunState, ThisContext, Step, Locals and so on.

And me it is continuing very embarrassingly you to trouble.

best reguards

Tumbler
0 Kudos
Message 24 of 49
(1,832 Views)
Hello Ray Farmer,

in the reply 23 you wrote some code. I don'T know where i should enter that.

reguards from germany

Tumbler
0 Kudos
Message 25 of 49
(1,826 Views)
Hi,

[Now i have made an LabView Vi i can enter an String. This vi i have changed with the selector Message Pop up. the view error selector show my entered string.
]

Thought you said you had created a VI, so I was referring to that VI.

Regards
Ray Farmer
Regards
Ray Farmer
0 Kudos
Message 26 of 49
(1,824 Views)
O should i enter this in my vi?

Or should i create two If loops with this loop configration? And in my vi i enter Locals.Error as an expression?
An in the Active x element i enter this PropertyObject.SetValString("Locals.Error", 0x1, )

Have i understand it wright?
0 Kudos
Message 27 of 49
(1,825 Views)
Hi,

Could you refresh your example, so I can get a clear picture of where you upto.

In response to an early message
[What is the diffrent between FileGlobals, StationGlobals and ThisContext.FileGlobals ,StationGlobals and the FileGlobals and StationGlobals in RunState.ThisContext. Where can i get some documentaion about the Expression and his functions or the diffrents between RunState, ThisContext, Step, Locals and so on.]

FileGlobals, this is where you place variables that are in scope of the whole of the SequenceFile. By default, each SequenceFile has its own FileGlobals, but you can make multiple SequenceFile share a common FileGlobals. This setting is found in the SequenceFile Properties. If you change a FileGlobals during executions, it stay that value until you change it again during the execution, once the execution is completed the change is lost an the FileGlobals will revert back to its static condition.

StationGlobals, these are variables that are in scope to every SequenceFile. If you change the value of StationGlobals, this new value is retained when the execution completes and also when the SeqEditor/Operator Interface closes. StationGlobals are not held as part of the SequenceFile, but in there own file in the TestStand\Cfg folder.

You can find a breakdown of the Sequence Context in the TestStand API help file. Also the TestStand Reference Manual should give you a bit more information on FileGlobals, StationGlobals.



[And in my vi i enter Locals.Error as an expression?]
No in your VI you would use the API call via an ActiveX Invoke Node to call PropertyObject.SetValString("Locals.Error", 0x1, ). First you would get a PropertyObject reference from the SequenceContext and use an ActiveX Invoke Node and use AsPropertyObject method. If you use one of the TestStand VI's then must of the work has been done for you.



Regards
Ray Farmer
Regards
Ray Farmer
0 Kudos
Message 28 of 49
(1,822 Views)
Hello,

Here is my Example. Still Displaytest3.seq. The Problem is that the Local Variable will create only in the runtime copy. I want to create for example in Displaytest3.seq in this step ho had creat an error. The Variable should be created permanetly such as i made it from hand in TestStand.
0 Kudos
Message 29 of 49
(1,820 Views)
Hi,

I have made a few changes to your ErrorHandler.seq. I have to use TS version 3.0 but it should work the same in TS3.1

I am not using you sequence ErrorTextEnter. Instead I am using the Response on the MessagePopup. If Locals.Error exists then I put the contents into the initial Response.

Any see what you think.


Not sure why you want to dynamical create Locals.Error. Keep it simple, declare it statically, just empty it at runtime if no error and check for an empty string.


Regards
Ray Farmer
Regards
Ray Farmer
0 Kudos
Message 30 of 49
(1,811 Views)