how can I read text in browser and export the same into text
file?
Answer Posted / akhaleshyadav1985
systemutil.Run "Iexplore","www.gmail.com","open"
wait 10
Set desc=description.Create()
desc("micclass").value="WebElement"
desc("html tag").value="P"
Set a=browser("title:=.*").page("title:=.*").ChildObjects(desc)
b=a.count
msgbox b
For i=0 to b-1
d=a(i).getroproperty("outertext")
a(i).highlight
print "Text -->" & d
Next
Dim Fso,file_loc,Fc,Forreading,d
Set Fso=createobject("scripting.FileSystemObject")
Set Fc=Fso.OpenTextFile("C:\aa\akh.txt",Forwriting,true)
Fc.Writeline(d)
Akhalesh Yadav
9555717928
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
How to use the object spy in quicktest professional (qtp) 8.0 version?
how can we test the Triggers, Cursors, Indexes while doing Database testing in DTP??
How to use reporter.report event in qtp ?
Both static and dynamic arrays are handled by the vb script. Is it true?
what is key word driven frame work ? why it is called like that ? what is the diference between keyword driven and data driven frame work ?
What processes will be required to manage updates to the web site's content, and what are the requirements for maintaining, tracking, and controlling page content, graphics, links, etc.?
How does you pass optional arguments in qtp?
what is supply chain management?
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
Will there be any standards or requirements for page appearance and/or graphics throughout a site or parts of a site?
How do I get the QTP scripts result in xml format by using vb script function?
images are dynamically changes how to compare two images with out using the bitmap
How to get the particular property value?
How do you handle multiple banners(at the top the page, the banner is scrolling) in a web page(Dont take the name property(regular expression))
i have an external excel datasheet where it only contains 3 rows. after qtp executed the code to import the datasheet, the datatable getrowcount method now gives me a different value, lets say 60,000+ instead of only 3. i did not have any values starting from row 4 of my excel file. why is this happening? this also results to the qtp report to load for a very long time.