06-06-2011 04:40 AM
I created a UI with Labview for my test stand seq. However I need the opperator to be able to select diffrent test seq depending on the unit under test. But when selecting the open seq files function, it always opens at the last used path. How can iI set this path from my UI before selecting the open seq files function so that It will open at the correct set of seq files for the selected device?
06-07-2011 11:06 AM
Hi PercyH,
I think I understand what you are trying to do. However, could you clarify the part about the open sequence files function? Is that an option as part of your UI or are you talking about literally going into the file menu in TestStand and selecting the open sequence file option? Could you reply with a screen shot of your UI. I look forward to your response.
Regards,
Josh L.
06-08-2011 01:01 AM
Hi there
Thank you for replying.
Maybe I must clarify things a bit more.
Create a seq file with test stand and save it in "C:\test1" and create a second seq file and save it in "C:\test2".
Now take the UI created for CD Test in the TetStand II Customization Exercises trainig manual. (I attached the file) Now add a combo box to the UI and populate it with two options.
I want the user to select a option from this combo box during runtime. After the user selected an option and he selects the "Open Sequince File " button, the file brouser must open in directory "C:\test1" or "C:\test2" depending on the combo box selection.
Thank you for your assistance.
06-08-2011 09:31 AM
The API for displaying the open file dialog should have a parameter that is the directory in which to open.
You can also set the current working directory since that is often the default for an open file dialog if you don't specify a directory as a parameter. Not sure if LabVIEW has a built-in API for this. If not, you can make a C call to the following windows API (located in kernel32.dll):
BOOL WINAPI SetCurrentDirectoryA( __in LPCTSTR lpPathName );
Hope this helps,
-Doug