ItemCmdletProviderIntrinsics.Exists ItemCmdletProviderIntrinsics.Exists ItemCmdletProviderIntrinsics.Exists Method

Definition

Overloads

Exists(String) Exists(String) Exists(String)

Determines if an item at the given path exits.

Exists(String, Boolean, Boolean) Exists(String, Boolean, Boolean) Exists(String, Boolean, Boolean)

Determines if an item at the given path exits.

Exists(String) Exists(String) Exists(String)

Determines if an item at the given path exits.

public bool Exists (string path);
member this.Exists : string -> bool
Public Function Exists (path As String) As Boolean
Parameters
path
String String String

The path to the item to determine if it exists. It may be a drive or provider-qualified path and may include glob characters.

Returns

True if the item at the specified path exists. False otherwise.

Exceptions

If the path refers to a provider that could not be found.

If the path refers to a drive that could not be found.

If the provider that the path refers to does not support this operation.

Exists(String, Boolean, Boolean) Exists(String, Boolean, Boolean) Exists(String, Boolean, Boolean)

Determines if an item at the given path exits.

public bool Exists (string path, bool force, bool literalPath);
member this.Exists : string * bool * bool -> bool
Public Function Exists (path As String, force As Boolean, literalPath As Boolean) As Boolean
Parameters
path
String String String

The path to the item to determine if it exists. It may be a drive or provider-qualified path and may include glob characters.

force
Boolean Boolean Boolean

Passed on to providers to force operations.

literalPath
Boolean Boolean Boolean

If true, globbing is not done on paths.

Returns

True if the item at the specified path exists. False otherwise.

Exceptions

If the path refers to a provider that could not be found.

If the path refers to a drive that could not be found.

If the provider that the path refers to does not support this operation.

Applies to