Control delault Browse directory displayed in Input dialog

Technical support and scripting issues

Moderators: JRL, Dorian (MJT support)

Post Reply
Guest

Control delault Browse directory displayed in Input dialog

Post by Guest » Thu Nov 13, 2003 7:34 pm

I would like to control which directory is opened when the browse widget is pressed in the Input dialog. It appears the default is the directory that contains the previously opened file.

I have checked the Registry and it contains no settings that control the default directory for the browse window. I assume it is controlled by the properties in some Windows System object that could be controlled with VBS. I cannot find any resources to help me. Any ideas?

Thanks,
Bill

User avatar
Bob Hansen
Automation Wizard
Posts: 2475
Joined: Tue Sep 24, 2002 3:47 am
Location: Salem, New Hampshire, US
Contact:

Post by Bob Hansen » Thu Nov 13, 2003 11:07 pm

You mentioned:
browse widget is pressed in the Input dialog. It appears the default is the directory that contains the previously opened file.
There are a number of variables that I tried to see what happened, but none of them worked. :( I tried:
Let>Script_Dir=C:\windows
Let>CWD=C:\Windows

What was interesting was that changing CWD to another path is only good for one line of commands. It immediately goes back to the default. :!:

:idea: Until there is a solution (another user defined variable sound good), you could make a variable for a path, and include that as part of the default value.....something like this:
Let>Path=c:\MyFolder\SubFolder\
Input>fullname,Enter the file name at the end of the default path,%Path%
Message>File to be processed is %fullname%.
Unfortunately this does not allow browsing, filename still needs to be typed. :(

:!: :!: AHA! I am sure you can call the Open Dialog from VBS and set the values in the VB section. Pass the results to the variable you were using for the Input> command. No time to do the code now, maybe someone else can do that for you.
Hope this was helpful..................good luck,
Bob
A humble man and PROUD of it!

Post Reply
Sign up to our newsletter for free automation tips, tricks & discounts