[Overview][Types][Classes][Procedures and functions][Index] Reference for unit 'ShellCtrls' (#lcl)

TCustomShellTreeView.ExistsAndIsValid

Checks whether the specified path is a valid file system object and type for the tree view control.

Declaration

Source position: shellctrls.pas line 115

protected function TCustomShellTreeView.ExistsAndIsValid(

  APath: string

):Boolean;

Arguments

APath

  

Path name examined in the method.

Function result

Returns True if the specified path exists and is valid for the object types displayed on the control.

Description

ExistsAndIsValid is a Boolean function used to determine whether a file system object at the path specified in APath can be displayed on the tree view control.

APath is a UTF-8-encoded fully-qualified path name. File attributes for the argument are retrieved to check whether it exists on the local file system. ObjectTypes is checked to determine whether the item is one of the object types displayed on the tree view control; this includes checking whether the otHidden object type setting matches the file system attributes for the path.

The return value is False if both conditions are not satisfied. The return value is True if APath a valid file (or directory) on the local file system.

ExistsAndIsValid is used in the UpdateView method when the Path and expanded state for a Selected node are updated.

Version info

Added in LCL version 4.0.

See also

TCustomShellTreeView.ObjectTypes

  

Indicates the file system objects displayed using the control.

TCustomShellTreeView.Path

  

Path to the directory displayed in the shell control.

TCustomShellTreeView.UpdateView

  

Reloads the nodes for tree view control and synchronizes an associated ShellListView control.


Version 4.0 Generated 2025-05-03 Home