Shouldn't the .FileExists() method support wildcards?

Advertisement

dotps1
Contributor
Joined:
Posts:
20
Location:
United States

Shouldn't the .FileExists() method support wildcards?

Shouldn't the .FileExists() method on the Session object support wildcards?

Similar to in powershell to like
PS C:\> Test-Path C:\Wind*
True
Its difficult to test if a wildcard is used, you'd have to test if a wildcard is in the string, then parse the directory from the path, the enumerate, then see if its greater then 1, i guess.

Reply with quote

Advertisement

dotps1
Contributor

i definitely get i could do it with that enumeration method, i just me logically if there is a file called test.txt then $session.FileExists(./test*) should be true, because that file "does" exist.

Reply with quote

Advertisement

You can post new topics in this forum