|
-
Feb 9th, 2011, 08:29 AM
#1
Thread Starter
Junior Member
Search webpage for a word or phrase?
Hey everyone!
I have a simple question, and I hope it has a simple answer 
Here is the code I have so far:
Code:
If browser.LocationURL = "www.anysite.com" Then
This works fine, but instead of checking the location, I want it to check if the webpage has the word "blah" in it. I thought maybe checking browser.document or something, but I couldn't figure out how to do it.
Thanks!
Last edited by bowiz2; Feb 9th, 2011 at 01:52 PM.
-
Feb 9th, 2011, 12:54 PM
#2
Re: Search webpage for a word or phrase?
You might look at this article and just search the resulting string with InStr.
The time you enjoy wasting is not wasted time.
Bertrand Russell
<- Remember to rate posts you find helpful.
-
Feb 9th, 2011, 01:18 PM
#3
Thread Starter
Junior Member
Re: Search webpage for a word or phrase?
 Originally Posted by jemidiah
You might look at this article and just search the resulting string with InStr.
Thanks! But I'm not great with strings-how can I implement InStr into an If statement?
-
Feb 9th, 2011, 01:52 PM
#4
Thread Starter
Junior Member
Re: Search webpage for a word or phrase?
Nevermind, I have answered my own question!
Code:
If InStr(text, "blah") = 0 Then
Changing to answerd!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|