TOpenDirectory
Version 3.02  -  May 7, 2002

Home page http://www.delphicity.com



TOpenDirectory package install

1. If a previous TOpenDirectory package is already installed, remove it first:

- Components | Install Packages,

- click on "DelphiCity TOpenDirectory",

- click "Remove",

- click "Yes",

- click "Ok",

- search for all the "TOpenDir.*" and "OpenDir.*" files in your Borland directories and delete them, to be certain that old units will not remain in the search paths (causing later raw errors). 

2. Install the current package:

- unzip the archive in a folder of your choice,

- according to your Delphi or C++Builder version, copy all the Delphi\*.* or CBuilder\*.* archive files to the Borland\Delphi\Imports or \Borland\CBuilder\Imports directory,

- run Delphi or C++Builder,

- select Component | Install packages,

- press the "Add" button,

- locate the TOpenDir.bpl file in the Imports directory and select it,

- select Open,

- select Ok,

- check the DelphiCity tab in the right of the component palette. The TOpenDirectory object should have been added.

C++Builder users: if you get a "BPL library not found" error at runtime, uncheck the "Build with runtime packages" check box in Project | Options | Packages.



METHODS

function Execute: boolean;
Displays the TOpenDirectory dialog box. 
Returns true if the "Open" button has been selected, false if the "Cancel" button has been clicked. 
If true, the selected directory is returned by the DrivePath and/or UncPath properties.



PUBLIC PROPERTIES

property DrivePath: string;
returns the full path of the selected directory if the directory is owned by a local drive or the directory is owned by a network resource and a drive letter is mapped to this network resource. 

If the selected path is owned by a network resource and not mapped to a drive letter, an empty string is returned. 

property UncPath: string;
returns the full path of the selected directory if the directory is owned by a network resource. 

If the selected path is owned by a local drive, an empty string is returned. 



PUBLISHED PROPERTIES

property EnableSizing: Boolean;
if enabled, the dialog can be resized when it is displayed.

property InitialDir: string;
sets the initial directory shown when the dialog opens. 
If InitialDir is left blank, the dialog shows the current directory.

property NoChangeDir: Boolean;
if false, the selected directory becomes the new current directory,
if true, the selected directory does not affect the current directory.

property Title: string;
Sets or retrieves the text that appears in the title bar of the dialog. If no value is assigned, the default  title is “Open”.



EVENTS

procedure OnClose (Sender: TObject);
occurs when the dialog closes.

procedure OnFolderChange (Sender: TObject);
occurs each time a directory is selected.

procedure OnShow (Sender: TObject);
occurs when the dialog opens.

 



Disclaimer

The author of this program accepts no responsibility for damages resulting from the use of this product and make no warranty or representation, either expressed or implied, including but not limited to, any implied warranty of merchantability or fitness for a practical purpose.

This software package is provided here "AS IS", and you the user, assume all risks when using them.



DESCRIPTION

TOpenDirectory is a VCL dialog component for Delphi or C++Builder.

TOpenDirectory allows to select local and network directories with one mouse click.

Most common parameters can be simply set from the Object Inspector.

Register and you will get the full source code.



features

- intuitive dialog,

- looks like a TOpenDialog,

- allows to create new folders,

- retrieves the drive path of local directories,

- retrieves the UNC path of network directories,

- retrieves both the drive path and the UNC path of network directories mapped to local drives.



System requirements

 

REGISTRATION

Click here to register.