---- Borland's Delphi Discussion List <[email protected]> wrote:
>
> Hello,
> I would like to use in my application a dialog box to browse
> the folders and to retrive a path. The IDE of Delphi 7 shows
> such a box, if you select "Projects/Options/Directories" and
> then you click on the Ellipsis button (...) of Output
> Directory, then a dialog box is shown in which you can
> browse the directories and choose your output directory. I
> would like such a dialog box to reztrieve a path which I can
> use later in my application.
> 
> Is such a component available? The components which are
> offered by the component palette are all more specialized.
> Have I to develope a new component? Which is the best way to
> learn to do this?
 
The Win32 "Browse for Folder" functionality that you're referring is actually 
performed by an API called SHBrowseForFolder().

There are many, many component wrappers for that available on the NET; many of 
them free.

Here's a couple of sites that show how to prepare for and call 
SHBrowseForFolder() directly from Delphi code (it's not particularly 
complicated):

  http://www.cryer.co.uk/brian/delphi/howto_browseforfolder.htm
  http://www.festra.com/eng/snip01.htm

You may not ever want to do that given how many component implementations are 
out there; but it's instructive to see what's actually going on behind the 
scenes.

Beyond that I'd suggest doing a search on Torry's or DSP for "Browse for 
Folder" and/or "SHBrowseForFolder" and you should get plenty of hits.

HTH

Stephen Posey
[EMAIL PROTECTED]
_______________________________________________
Delphi mailing list -> [email protected]
http://www.elists.org/mailman/listinfo/delphi

Reply via email to