NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Clearing the TS Output pane

Hi all,

 

I'm posting output messages into the Output pane of TestStand using statements like this:

 

OutputMessage( NameOf(RunState.Step), "Statement Step",0, tsDarkGreen,"statement.ico")

 

So far all is good.

 

My problem is ... after completing a full test cycle where the Output pane now contains maybe 20 messages - how do I clear this ready for the next unit for test? If I just leave this, it will just keep appending!

 

I have looked here: C:\Documents and Settings\All Users\Documents\National Instruments\TestStand 4.1.1\Examples\OutputMessages

 

and see: 'Locals.OutputMessage = Nothing' in the example .seq but this is only for active x mesage posting?

 

Nothing to this effect in the manuals!

 

Any help appreciated

Andy

 

 

 

 

0 Kudos
Message 1 of 5
(4,280 Views)

try

 

Engine.GetOutputMessages

then

OutputMessages.Clear

 

 

Regards
Ray Farmer
0 Kudos
Message 2 of 5
(4,272 Views)

Thanks Ray, I tried your sugestion but unfortunatly it didn't clear the ouput pane only the engine - thanks anyway for the good sugestion.

 

It seems the output message storage and the output message display/storage are
separate and so two clears are required to fulfil my request to clear the
output message system and output pane. This was after replies from NI support.

 

For anyone else wanting to know about this NI support said this:

 

"it seems that the OutputMessages.Clear method does indeed clear the collection of output
messages from the collection in the teststand engine.
I proved this by using an OutputMessages.count call before and after my clear
method.

It seems that the problem here is that they have already been posted from the
collection in the engine to the output pane. There appears to be no physical
link between the engine and the pane so clearing the collection doesn't clear
the pane.

It seems that we need a handle to the output pane, hopefully then we should be
able to find a method that will clear the messages that are already posted.
I must admit, I can't see any obvious way to achieve this at the moment. I will
raise an escalation with our teststand tech support team in the USAto see what
they can suggest.

I am afraid its not good news. It is not possible to programmatically clear the output messages pane in the TestStand environment . I was hoping we would be able to get a handle to the output pane and then call a method to clear it, but this functionality is not available.

I will file a corrective action request with the research and development department, in the hope they may add this functionality in future TestStand releases.
For the moment, it seems that you only have a couple of options,
The first is to allow the debug window to collect all of the information (even if we periodically clear the collection from the TestStand engine). You could add few extra messages or spaces to ensure there is a break between messages associated with different runs,
The other option would be to produce a separate user interface to which we can post messages (and remove them) rather than using the outputmessage functions.

I am sorry that it has taken so long to get to the bottom of this, I was really hoping that we would be able to find a suitable method of clearing the pane."

 

So there you have it - the Output pane cannot be programatically cleared! It does seem strange to me as TS is promoted as the most felexible adaptable customisable product ever and generaly it is. I guess occasionaly the odd item gets overlooked?

 

 

Message 3 of 5
(4,220 Views)

I'm curious now regarding two points -
1) Whether is it still not possible to clear Output messages pane programatically?
2) How it influence on the performance of the TestStand? How much it increases the memory, if messages will be posted continuously to Output pane?

 

Thanks a lot,

 

Sincerely, kosist90

 

logos_middle.jpg

0 Kudos
Message 4 of 5
(3,591 Views)

I am having similar issues and came across this thread.  I've tried the following below with no luck.

 

// Using C#.

OutputMessages? outputMessages = sequenceContext.Engine.GetOutputMessages();
outputMessages?.Clear();

 

Anybody have a solution to clear programmatically?

0 Kudos
Message 5 of 5
(2,224 Views)