NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Labview-Action doesnt activate window when called in teststand

Hello,
I have two small test-Vis.
What they do is:
 
First VI:
a.) Starting notepad.exe
b.) get refnum of the notepad-window
c.) Make it topmost with the lvutil.llb
d.) Write a text in it with "keybd_event"
 
Second VI:
The Same like in 1.) but without starting notepad (the program is already open.
 
 
When i run this two VIs in labview one after another it works without problems.
When i run them as Actions in "NI Teststand" then it only works if i run both in "one run".
 
But if i cklick first the first vi and "run selected step" and then the second vi with "run selected step" then the second VI only brings the notepad-window to foreground but doesnt activate it. And without activation the text is not written in the notepad-window.
 
Is there any trick i can do to always activate the window?
Im uing Windows2000 /LV 7.1.1 / Teststand 3.1
 
Thx for any help.
0 Kudos
Message 1 of 2
(2,965 Views)
This thread continuous here
Ingo Schumacher
Systems Engineering Manager CEERNational Instruments Germany
0 Kudos
Message 2 of 2
(2,953 Views)