With the below command I am able to revert a virtual machine in vmware workstation to a snapshot mentioned.
$sVMPath = <path of the vmx file of virtual machine>
$sSnapshot = <snapshot name>
$Ret = RunWait(@ComSpec & " /c VMRun.exe -T WS revertToSnapshot ""$sVMPath$"" ""$sSnapshot$"" nogui", ""...