ho to verify by VB script syntax if the file conf C:\Program Files\conf exist under Program Files ?
for example if it exist then msgBox print file exist if not the msgBox print file not exist THX
ho to verify by VB script syntax if the file conf C:\Program Files\conf exist under Program Files ?
for example if it exist then msgBox print file exist if not the msgBox print file not exist THX
There is no built-in functionality in VBS for that, however, you can use the FSO object for that:
Option Explicit
DIM fso
Set fso = CreateObject("Scripting.FileSystemObject")
If (fso.FileExists("C:\Program Files\conf")) Then
WScript.Echo("File exists!")
WScript.Quit()
Else
WScript.Echo("File does not exist!")
End If
WScript.Quit()