Skip to main content

TcxCustomShellTreeView.AbsolutePath Property

Specifies the path to the shell item being accessed via the starting folder.

Declaration

property AbsolutePath: string read; write;

Property Value

Type
string

Remarks

Use this property to specify the path to the required shell node. Any folder path can be specified in two ways:

  • As a full path, including a sequence of all folders required for accessing the required shell node from the shell root.

Example:

cxShellTreeView1.AbsolutePath := 'C:\Documents and Settings\Administrator\My Documents\My Pictures';
  • as a relative path, providing access to shell nodes within the current folder.

Example:

cxShellTreeView1.AbsolutePath := 'My Pictures';

The AbsolutePath property allows a user to access both virtual and standard shell items. Note that virtual shell items have no analog on the hard disk. You need to specify one of the virtual shell item path prefixes before the virtual shell item name. The cxShellObjectInternalAbsoluteVirtualPathPrefix constant allows accessing the required shell item from any current folder. The cxShellObjectInternalRelativeVirtualPathPrefix constant allows accessing the required shell item from the Root folder. Examples of virtual shell items include:

  • Network printers
  • Other networked computers
  • Control Panel applications
  • Recycle Bin

Example of accessing the Recycle Bin shell item via the absolute and relative virtual path prefix:

cxShellTreeView1.AbsolutePath := cxShellObjectInternalAbsoluteVirtualPathPrefix + '\Recycle Bin';
cxShellTreeView1.AbsolutePath := cxShellObjectInternalRelativeVirtualPathPrefix + '\Recycle Bin';

During navigation through the folders, the AbsolutePath property stores the path to the currently accessed shell node.

Note

the AbsolutePath property must contain folder names only. Specifying the file name within the AbsolutePath property causes unpredictable results.

See Also