I wish to delete a FileGlobal variable through TestStand from all the sequences which are opened or from all the sequence files which are present under project or workspace. I don't want to open each file and then delete that variable from there. Do we have anyway of deleting that FileGlobal variable from all sequence files on few clicks.
If you mean from the Variables window (FileGlobals), so you can choose the first variable and pressing the Shift button to choose the last one, then press/choose to delete. With this action, the whole Global variables will be deleted from all sequences.
I don't want to delete all the FileGlobal variables.
I want to delete single FileGlobal variable (eg- FileGlobals.EngineHours) from multiple sequences which are opened in TestStand.
Here is a sequence file that shows how to create a fileglobal on the fly (in this case a boolean), as well as delete it.
create "test" fileglobal:
Locals.TemporaryObjectReference = RunState.Engine.NewPropertyObject(PropValType_Boolean,False,"",0), //Create new property Object
Locals.TemporaryObjectReference.AsPropertyObject.Name = "test",
FileGlobals.InsertSubProperty("",0,0,Locals.TemporaryObjectReference) // Insert property into station globals
delete "test" fileglobal
Hope this helps...
If I use this way, then I need to go in each sequence file and run these steps to delete variable. If I have 100 files with variable, then repetition of these steps will be time consuming.
Anyways, Thanks for your reply!
Use this VI over each SequenceFile with appropriate FileGlobal value (without the FileGlobals. prefix)
I could not open this VI because I am using LabVIEW 2017.
I think this VI is made in newer version.
Please find the VI in attachment, I saved it based for LabView 2017.