So I created this code, it will run once the user logs in.
You may see I'm a newbie in vbs, I am just checking if the file exists, but how can I check the file version?
Any hint will be very appreciated
Dim objShell
Set WshShell = CreateObject("WScript.Shell")
strHomeFolder = WshShell.ExpandEnvironmentStrings("%USERPROFILE%")
Set objShell = WScript.CreateObject( "WScript.Shell" )
Set fso = CreateObject("Scripting.FileSystemObject")
If fso.FileExists(strHomeFolder & "\lspush.exe") Then
objShell.Run(strHomeFolder & "\lspush.exe 192.168.0.1")
Else
fso.CopyFile "\\192.168.0.1\Client\lspush.exe", strHomeFolder & "\"
objShell.Run(strHomeFolder & "\lspush.exe 192.168.0.1")
End If
Set fso = Nothing