Sign in Join
FPDoc Onlineexperiment

TCustomShellTreeView.ExistsAndIsValid function

Member of TCustomShellTreeViewprotectedIn unit ShellCtrls

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

Declaration

pascal
function 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.

Added in LCL version 4.0.

See also

An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.