if the excel sheet specified in script is not there,we get
run time error how to handle the error ,please anybody
explain me in detail
Answer Posted / veeranki naveen
On error resume Next
err.clear
set Excl = createobject("excel.application")
set Workbook=Excl.Workbooks.open("C:\Folder\ExcelFile.xls")
if err.number <> 0 then
msgbox "Excel Sheet is not present at the specified path"
End If
OR
set fso = createobject ("scripting.filesystemobject")
bol = fso.fileexists ("C:\Folder\ExcelFile.xls")
if bol = false then
msgbox "Excel Sheet is not present at the specified path"
End If
msgbox
Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
What is recovery scenario in qtp?
Why do we use breakpoints in QTP?
What is the extension of qtp local repository?
if there is a web table of having row and colmns.a button is placed at 2nd row's 3rd column which is worked for both edit and delete..how to write script for the button to test both operation on the web table using desriptive programing.. plz help me on script wheather using getroproperty Q2)what is the command for taking valiue from a web table in qtp
How many add-ins comes by default with quicktest professional (qtp)?
What are the general steps involved in the data driven framework?
Where to use function or action?
In qtp, explain what is keyword driven automation framework?
wht type of User defined functions or Java Releated functions Do we write in VB scripting
i need to add 1000 users in a domain i written the script for that and it is running successfuly but the problem is that my system is not the user of that domain in which i have to add users so for adding users in that domain i have to install qtp on that another system, can anybody suggest me the way to add those users from my system ultimately i want to know how to access remote computer through script
What is the Difference between copy to action and call to action?
what is clean sweep?
For which type of project the iterative model is suitable?
What is the extension of the qtp local repository? If it is .mtr then what is .bdb extension stands for?
i am looking job in perfomance testing using Loadrunner any one help me a project plz......?(Chandana) chs_29@rediffmail.com