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
ACTUALLY I AM WORKING IN THE DISTRIBUTION DOMAIN.MY COMPANY IS PROVIDING DISTRIBUTION SOFTWARE FOR PHARMA AND FMCG DISTRIBUTORS.HERE I AM USING QTP 9.2.HERE IN MY APPLICATION WHILE RECORDING ONE WINDOW APPEARS.IN THAT I CAN SELECT THE ITEM OR NO NEED TO SELECT.BUT WHILE RUNNING THE SAME SCRIPT THE WINDOW MAY NOT APPEAR OR APPEAR.HOW TO WRITE SCRIPT FOR THIS
How to use parameterization in qtp?
Can any one send me the QTP Basic Coding Samples?
If u r using library files (Instead of Check Points) , How do u do bitmap check ?
hi i have 4 yrs exp in manual and automation testing using QTP i need sample resumes plz can u send this mail id pbre1980@gmail.com
Hai anyone please "Explain about Framework in QTP?"
what is the difference between rational rose and QTP? WHICH TOOL IS BETTER TO LEARN? PLEASE SEND ME AT sana_50218@yahoo.com sandeep@epuratech.com
What is the Command used to start the QTP
What are main panes available in qtp test browser?
what are the critical test cases in crm? tell me atleast 5 critical test cases? what are the critical bug u find out while testing crm domain?
What is difference between design time and run time data table?
In an interview, what r the general questions asked in QTP? pls give me anwser to this question?
UFT 12.02 which ALM version will support
Is it possible to switch between recording modes during a test creation?
What are the differences between table and db checkpoints?