Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
need vbscript to search for a "text string" on a google search page ?
#1
Not Solved
for eg. On google search page, I enter text "advanced qtp" and click on google search button. It shows no. of pages with result. I want to search for a specific text "Advanced Qtp - Students Hang Out". But I dont know on which page the expected text is lying. My script shd look for the expected text "Advanced Qtp - Students Hang Out" on each page one by one and if it finds the expected result then it shd show a message PASS and the page no. can anyone send me the script ?
Reply
#2
Not Solved
you should ask for a praticular issue you face to resolve your tasks rather asking for complete script. if you try yourself, you will learn more.

what we can help you now is with guidelines if you need -
1. after submitting your text at google page get all the links from page you can use 'Description.Create' method.
2. get the current page initialized as 1.
3. loop through all the links you get and look for the text in each link, you can use 'instr' if found return the link and current page
3. click the next page link and do the same again

let us know if you face any issue in implementing this.

Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  how to select value from google search box dropdown +QTP prajyot 0 2,902 06-28-2017, 06:30 PM
Last Post: prajyot
  Search and import data from excel under some rules. nwpulele 2 2,919 02-19-2015, 04:10 AM
Last Post: supputuri
  Read text from text file and save it into a variable in qtp arpan 3 12,974 06-19-2013, 08:34 PM
Last Post: arpan
  get all text showing on web page daniel_QTP 3 14,223 09-25-2012, 12:44 PM
Last Post: jesonvan
  Need to compare two text files - ignoring some text nelly27281 2 4,584 09-09-2012, 12:09 PM
Last Post: freeboynil

Forum Jump:


Users browsing this thread: 1 Guest(s)