Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Remote server machine does not exist
#4
Solved: 10 Years, 9 Months, 2 Weeks ago
Option Explicit
''**********************************************************************
Code:
'Script Name: DriverScript
'Author:  
'Date of Design: 12-Apr-2013
'Date of last Revision: 12-Apr-2013
'Functions Called:
'Description:  'This Script performs:-
     '1.Logging into the application
                '2.Closing Excel spreadsheets which are open
                '3.Importing the TestCase spreadsheet
                '4.Executing the Test Case by calling the corresponding actions
'******************************************************************

Code:
SystemUtil.CloseProcessByName("IExplore.EXE")
SystemUtil.CloseProcessByName("EXCEL.exe")

'***** Opening and retriving data from excel file
Dim objExcel
Dim intCntrl
Dim strRun
Dim strStatus
Dim objworkbook
Dim objExcelSheet
Dim introwCount
Dim intcolCount
Dim intcounter

Set objExcel=CreateObject("Excel.Application")

Set objworkbook=objExcel.workbooks.open("D:\AutomationTesting\TestData\TestData.xls")

Set objExcelSheet=objworkbook.worksheets("Run Sheet")

introwCount=objExcelSheet.usedrange.rows.count

intcolCount=objExcelSheet.usedrange.columns.count

For intcounter=2 to introwCount-1

intCntrl=objExcelSheet.cells(intcounter,1)

strRun=objExcelSheet.cells(intcounter,2)

strStatus=objExcelSheet.cells(intcounter,3)

                If strRun ="Yes" then  

                     RunAction "Action1 ["&intCntrl&"]", oneIteration

                     Wait(20)

                    objExcel.objworkbook("TestData").Activate
                  
                    objExcelSheet.cells(intcounter,3).Value = "Executed"

                  End If

objExcel.DisplayAlerts = False

Next

'Set objExcelSheet = Nothing

objExcel.DisplayAlerts = False

objExcel.Save

objworkbook.Save

objExcel.DisplayAlerts = True

objExcel.Quit

Set objExcel = Nothing


after completion of this execution it has to update the "Executed" in the test data excel sheet but here I am getting the error msg as

"The remote server machine does not exist or is unavailable: 'objworkbook'
Line (53): "objExcel.objworkbook("TestData").Activate "

The remote server machine does not exist or is unavailable: 'cells'
Line (55): "objExcelSheet.cells(intcounter,3).Value = "Executed"".

Kindly look into this and do the needful

Regards,

Sreekanth
Reply


Messages In This Thread
Remote server machine does not exist - by eroshan - 10-14-2009, 11:59 AM
RE: Remote server machine does not exist - by sreekanth.peetla - 05-03-2013, 10:27 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  General run error when Exist fails msacks 1 1,684 02-08-2019, 02:12 AM
Last Post: Ankur
  Need script to connect remote machine stalinvanama 1 1,490 09-27-2018, 08:12 PM
Last Post: stalinvanama
  [UFT 12.52/VBScript] Test object exist, is visible and enabled before take an action sparkwanted 0 3,456 02-07-2017, 12:28 AM
Last Post: sparkwanted
  how to find Excel file exist or not in vbscript code sree.85 3 10,852 08-22-2013, 11:42 AM
Last Post: akhandesh
  executing qtp on a remote machine sujaravi123 4 4,542 08-02-2013, 01:22 PM
Last Post: sujaravi123

Forum Jump:


Users browsing this thread: 1 Guest(s)