Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Driver Scripts and Result Viewer
#1
Not Solved
Hi All

Im using Driver Scripts to Run All my Test scripts(Series of Scripts ),BUt the problem is Its only Showing the Results for the Last Run ,Could any One Here Help me for Getting the Results All the Run-Scripts

This is my Scripts -Which I saved it as .VBS and i have Attached The Controller Sheet ,Could one here Please Analysis this Please bring me A suggestion on this
Code:
''launching qtp
Set QTapp = CreateObject("QuickTest.Application")
If not QTapp.Launched Then
     QTapp.Launch
     QTapp.Visible = True
End if
Set qtResultsOpt = CreateObject("QuickTest.RunResultsOptions")
qtResultsOpt.resultslocation="C:\Users\rsubrama\Desktop\result\"
ConPath = "C:\Users\rsubrama\Desktop\ControllerSheet.xls"
TestSuitePath = "C:\salesforce\Automation\Scripts\"
Set Exlapp = CreateObject("Excel.Application")
set wbook = Exlapp.Workbooks.Open(ConPath)
Set wsheet = wbook.Worksheets(1)
rc = wsheet.usedrange.rows.count

For i = 2 to rc
      sFlag = wsheet.cells(i,2).value
      If sFlag = "True" Then
          scrName = wsheet.cells(i,1).value
          resultName=wsheet.cells(i,6).value
          '' Open the script in qtp and associate and run
                QTapp.Open TestSuitePath & scrName ,False
                ''Associating the libraries
                
                QTapp.test.Run qtResultsOpt
            




                ''To read the status of Test execution
                
                result = QTapp.Test.LastRunResults.Status
            
                wsheet.cells(i,3).value =result
                If result = "Passed" Then
                      wsheet.cells(i,3).interior.color = vbgreen
                Else
                    wsheet.cells(i,3).interior.color = vbred
                End If
                'QTapp.Test.close        
        
    
     End If

Next


wbook.Save
wbook.Close
Exlapp.Quit
Exlapp = Nothing
QTapp = Nothing
QTapp.Quit


Attached Files Image(s)
   
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  How to send/pass UFT Run Error Dialog as output value to main driver script lravi4u 0 583 11-05-2023, 03:55 PM
Last Post: lravi4u
  Driver Script to control child scripts sumanhyd 1 3,180 07-26-2016, 07:06 PM
Last Post: Ankesh
  Report Viewer showing hundreds of WebElement.Exists? themoon 1 2,335 03-09-2016, 02:43 PM
Last Post: vinod123
  How to Export run result viewer with CAPTURED DATA and save it in PDF,or Doc,or HTML akhandesh 0 2,950 07-16-2015, 06:03 PM
Last Post: akhandesh
  How to capture objects of Event Viewer ? Vishnu Narayan 1 2,585 06-11-2015, 06:29 PM
Last Post: venkatesh9032

Forum Jump:


Users browsing this thread: 1 Guest(s)