Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

GetFileOpenName - Starting directory

Status
Not open for further replies.

notthelastone

Programmer
Sep 30, 2004
1
CH
Hi

I am trying to use GetFileOpenName to open a FileOpen Dialog box.
But I need it to open from a predefined directory (i.e InitialDir). How do I do this, GetFileOpenName does not allow me to start from a directory instead it starts from the current directory.

I tried to use SetCurrentDirectory (windows function call), but it doesn't start from the current directory which I just set using SetCurrentDirectory. This is a problem in Windows XP. But it had worked on WIndows NT.

Any ideas how to get around this in XP.

I am figuring out how to use GetOpenFileName (a windows API)to see if it will resolve the issue. GetOpenFileName allows InitialDir to be set up.

Any suggestions/solutions will be most appreciated.

PS: I am using PB7.0.3

Thanks
George
 
Use ChangeDirectory after you used SetCurrentDirectory

Arnold

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top