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
How can we extract data like "Details","Result","Time" from the 'Run Error' result generated in QTP after run time errors are generated during a run & import the details etc...into excel sheet
please post the interview questions for QA position in FACTSET
What are the types of data tables in qtp?
What are the common defects found in your project? (in qtp interview)
how do you parameterize search button from the website? the page is a single winobject and i have made a virtual object button of search button but search box can't be converted into a winedit and if we try to convert it into winedit the value we enter in a searchbox appears as numbers in the script so we arent able to parameterize.help!!!
How to analyzing the checpoint results?
What are the 3 main stages involved in testing with qtp?
Can anyone pls tell me in realtime (descriptive programming) how will the properties of the object be given to the test team. R they given in an excel sheet and is the same sheet also given to the development team and by whom is this given? Thanks a lot.
Hi could some one explan what is the use of the function Defination generator, And how to use the function defination generator.. Explan with the example..
How to export quicktest professional results to an .xls file?
how to download mercury qtp9.2 ny internet ?
What is the difference between run time object and test object?
i need qtp tutorial. pls send it to sridhar.k151@g mail.com
When to use descriptive programming?
HOw to add the recovery file at runtime to the test file .