Suppose there is a link present somewhere in an excel sheet.
Find the link and click on it. How to write a script using
Excel application object in QTP?
Answer / anup muralidharan nair
'Assume the link present in excel that you want to click is
'www.google.co.in
set oxls = createobject("excel.application")
set obook = oxls.workbooks.open("D:\excel.xls")
set osheet = obook.worksheets("sheet1")
'Retrieve all the hyperlinks within the sheet
set ohyper = osheet.hyperlinks
for each hyp in ohyper
If hyp.name = "www.google.co.in" Then
hyp.follow
End If
next
'close the book and release the excel object
obook.close
set obook = nothing
set oxls = nothing
| Is This Answer Correct ? | 4 Yes | 0 No |
I want to open a Google page without recording a test and i do not want to use system.Util.run command as well how do i do this?
What is Expert view?
What is recovery scenario in qtp?
what is object repository size?
How can I replace all the text from the QTP script with some other text. Is there any replace all function in QTP Any one can help me
How to capture screenshots of Exceptions/Errors during run- time?
Analyzing the checpoint results?
What is the difference between Action and Function.? when both has the same functionaltiy, when do we choose Action and when do we choose Function..??
3 Answers DST Global Solutions,
What is a reusable action?
Did u use check points during ur work experience ?
How to find local host name using QTP?
What is an Regular expression doing in VBScript?Tell the pattern for the email verification.