$cs.File\_ExistFile
Syntax
Section titled “Syntax”$cs.File_ExistFile(string filepath)
Parameters
Section titled “Parameters”filepath
Path to file to check for
Example
Section titled “Example”if(!$cs.File_ExistFile("${env:ProgramFiles(x86)}\WinSCP\WinSCP.exe")){ Exit-PSScript 2}returns Bool