Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Common Dialog control
Message
From
08/04/2004 14:40:47
Randy Riegel
Zimish Contracting
Ohio, United States
 
General information
Forum:
Visual FoxPro
Category:
ActiveX controls in VFP
Miscellaneous
Thread ID:
00893295
Message ID:
00893353
Views:
30
>>>>I'm trying to use a common dialog box to choose a directory. I want the user to be able to create directories as they are browsing and that is the reason I'm not just using the GetDir() function. I have use programs (ex. Macromedia Dreamweaver MX) that will pop up a common dialog box and allow to you select a directory without needing to choose a filename. How can I do this, I've look at all the common dialog help I could find. I'm using VFP6SP5 on WinXP Pro.
>>>
>>>Look at FAQ#7780, by my late friend Ed Rauh. I think this might give you the functionality you need.
>>>
>>>Optionally, you could use the Shell.Application object's BrowseForFolder method.
oShell = CREATEOBJECT("Shell.Application")
>>>oPath = oShell.BrowseForFolder(0, 'Title', 64, "C:\")
You'll get back an object reference that you'll have to parse. The Title property holds the name of the folder. You parse by going upward retrieving the ParentFolder object.
>>
>>
>>That works great, but I'm also wanting the functionality to create, rename, delete folders like when using the commondialog Open box. Any other ideas?
>
>Well, you should have the ability to create the folder by clicking the New Folder button. You can rename or delete by right clicking the selected folder and selecting Rename or Delete from the context menu.

The function in the faq and the BrowseForFolder method do not give me a new folder button, or right-click rename/delete ablitily like the common dialog does. The only thing about the common dialog is I can't select just a directory, it makes me choose a filename.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform