How to implement Find text in a webbrowser control?

Noviembre
Noviembre used Ask the Experts™
on
I'd like to implement the Find text feature in my application which uses a webbrowser control.
Anybody has a quick solution on how I can find and highlight text in a webbrowser control?
Thanks.
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Hi, Men!  You can download from msdn.com  "vbWebBrowser" sample,( http://msdn.microsoft.com/downloads/samples/internet/browser/vbwebbrowser/default.asp?frame=true )
 
and from it register wbaddrbook.dll
And just use WBAddrBook.ShowFind to show Find menu.

Author

Commented:
hi nightman2000,
  what an excellent reference you have suggested.
  however, I'm hoping to do everything in VB and not relying on external DLLs.
  is there a way to accomplish this?
  thanks.
Commented:
Hi,

I hope this will help.

In the webbrowser component is a default find implemented.
When the component has the focus, CTRL + F shows the system find dialog.

The following code sends this character combination the webbrowser:

    WebBrowser.SetFocus
     SendKeys ("^f")
 
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:
- answered by egn
Please leave any comments here within the
next seven days.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER !

twalgrave
Cleanup Volunteer
per recommendation

SpideyMod
Community Support Moderator @Experts Exchange

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial