Sign in to follow this  
Followers 0
Matthy

search string in value in IE

3 posts in this topic

$_Acc1oIE = _IECreate(1)
_IENavigate($_Acc1oIE,$site)
$sHTML = _IEBodyReadText  ($_Acc1oIE)

MsgBox(0,'', $sHTML)

i want him to check if the string thisworksfine is in the $sHTML but there is lots of more junk in the html

cant find a function to search in a value.

found _ArrayBinarySearch but dont think thats something

any ideas

cheers

matthy

Share this post


Link to post
Share on other sites



$_Acc1oIE = _IECreate(1)
_IENavigate($_Acc1oIE,$site)
$sHTML = _IEBodyReadText  ($_Acc1oIE)

MsgBox(0,'', $sHTML)

i want him to check if the string thisworksfine is in the $sHTML but there is lots of more junk in the html

cant find a function to search in a value.

You already have the HTML as a string, so it's just:

If StringInStr($sHTML, "thisworksfine") Then MsgBox(64, "Found", "Found it.")

If you need to do more complicated searches you could use StringRegExp() instead.

:)


Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law

Share this post


Link to post
Share on other sites

thanks i thought stringinstr whas for different things THX :)

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0