hi dear,
 
i am executing below mentioned code in QTP ,it is running successfully,but i am 
not getting below highlighted line(in yellowmark) what is doing ???
 
 
Dim oShell, oFSO
Set oShell = CreateObject("WScript.Shell")
Set oFSO = CreateObject ("Scripting.FileSystemObject")
'Install Visual C++ Run-time Component 2008
On Error Resume Next 
 s=oShell.RegRead("HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{3C3D696B-0DB7-3C6D-A356-3DB8CE541918}\DisplayVersion")
 If Err.Number = 0 Then 
  Reports.Report "Warning",Environment("TestName"),"Checking if Visual C++ 
Run-time 2008 is already installed.","Visual C++ Run-time 2008 was already 
installed.","Continue with HPACSP Prerequisite install."
 Else 
  Reports.Report "Pass",Environment("TestName"),"Checking if Visual C++ 
Run-time 2008 is already installed.","Visual C++ Run-time 2008 was not yet 
installed.","Begining install of Visual C++ Run-time 2008"
  PC.Application.CMD.ExecAndReadCommand """" & sGlobal_AutoPath & 
"Software\Microsoft\C++Redist2008\vcredist_x86.exe"" /q, 1, true"
  Wait 5
  On Error Resume Next 
   s=oShell.RegRead("HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{3C3D696B-0DB7-3C6D-A356-3DB8CE541918}\DisplayVersion")
   If Err.Number = 0 Then 
    Reports.Report "Pass",Environment("TestName"),"Checking if Visual C++ 
Run-time 2008 was successfully installed.","Visual C++ Run-time 2008 was 
successfully installed.","Continue with HPACSP Prerequisite install."
   Else
    Reports.Report "Fail",Environment("TestNam e"),"Checking if Visual C++ 
Run-time 2008 was successfully installed.","Visual C++ Run-time 2008 was not 
successfully installed.","Manual installation of the Visual C++ Run-time 2008 
is required."
   End If
  On Error GoTo 0
 End If 
On Error GoTo 0


thanks and regards
rahul bansal

-- 
You received this message because you are subscribed to the Google
"QTP - HP Quick Test Professional - Automated Software Testing"
group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/MercuryQTP?hl=en

Reply via email to