Photo Gallery Member List Search Calendars FAQ Ticket List Log Out


vb equivalent to window.find

 
Logged in as: Guest
arrSession:exec spGetSession 2,2,586
 Active Users: There are 0 members and 0 guests.
 Users viewing this topic: none
 

 

 
  
  Printable Version
All Forums >> [Scripting] >> WSH & Client Side VBScript >> vb equivalent to window.find
  Do you like VisualBasicScript.com? Link to us and help spread the word about our forum. Thanks!
Page: [1]
Login
Message << Older Topic   Newer Topic >>
 vb equivalent to window.find - 2/28/2002 6:49:39 PM   
  cjl

 

Posts: 1
Score: 0
Joined: 2/28/2002
From:
Status: offline
Please help. I have never used vbscript and I'm trying to find the equivalent to the javascript window.find method that will work in an ie browswer window. I need to allow the user to click a button that will bring up the browser find window. Is this possible with vbscript? Any input would be appreciated. Thanks.
 
 
Post #: 1
 
 RE: vb equivalent to window.find - 11/11/2005 6:07:39 PM   
  TNO


Posts: 1247
Score: 10
Joined: 12/18/2004
From: thenewobjective.com
Status: offline
I don't believe its possible in VBScript without using the SendKeys method (which would reguire an .HTA). IE doesn;t support window.find. JavaScript does support the Text Range object that could be used. But a vbscript equivalent is currently beyond me. (vbscript is my second language)

Here's the JavaScript solution:

http://www.javascripter.net/faq/searchin.htm

Hopefully my fellow Mods/Admins can assist in expanding on the subject.

_____________________________

To iterate is human, to recurse divine. -- L. Peter Deutsch

(in reply to cjl)
 
 
Post #: 2
 
 RE: vb equivalent to window.find - 11/11/2005 8:50:27 PM   
  ehvbs

 

Posts: 2173
Score: 50
Joined: 6/22/2005
From: Germany
Status: offline
Hi cjl,

as TNO pointed out, the TextRange object can be used to search the text of the page.
If you want to use this method - instead of trying to call the browser's find window -
this code


      

will get you started.

(in reply to TNO)
 
 
Post #: 3
 
 
 
  

If you found our site useful please link to us <a href="http://www.visualbasicscript.com">VisualBasicScript.com</a>.
All Forums >> [Scripting] >> WSH & Client Side VBScript >> vb equivalent to window.find Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts