Nishant Posted November 28, 2006 Posted November 28, 2006 I want to search a Text in my Web Page. Is this Possible? My Text is: "YAY! event triggered successfully Saved Document". I want to search this text in my web page, if this exists then My work is successful otherwise there should be some error. Can u please tell me about that. Is this possible? How? Thanks
NeoFoX Posted November 28, 2006 Posted November 28, 2006 #include <IE.au3> $oIE = _IE_Example ("basic") $sText = _IEBodyReadText($oIE) If StringInStr($sText, "language") = "" Then MsgBox(1,"test","not found the text language") Else MsgBox(1,"test","found text language") EndIf Will help you Neo [center][font="Arial"]--- The Neo and Only --- [/font][font="Arial"]--Projects---[/font]Image to Text converterText to ASCII converter[/center]
Nishant Posted November 28, 2006 Author Posted November 28, 2006 Thanks It Works. Thanks for your Help
Moderators big_daddy Posted November 28, 2006 Moderators Posted November 28, 2006 Just a small optimization. #include <IE.au3> $sURL = "www.YourWebpage.com" $sSearch = "Your Search String" $oIE = _IECreate ($sURL) If StringInStr(_IEBodyReadText($oIE), $sSearch) Then MsgBox(0 ,"Success","The text was found.") Else MsgBox(0 ,"Error","The text was NOT found.") EndIf
evilelf Posted November 28, 2006 Posted November 28, 2006 Just a small optimization. #include <IE.au3> $sURL = "www.YourWebpage.com" $sSearch = "Your Search String" $oIE = _IECreate ($sURL) If StringInStr(_IEBodyReadText($oIE), $sSearch) Then MsgBox(0 ,"Success","The text was found.") Else MsgBox(0 ,"Error","The text was NOT found.") EndIf Very Nice this now can help in alot of othere ways.
Tukata Posted November 28, 2006 Posted November 28, 2006 (edited) By the way, is there a way to add a button to the HTML source code which will triger the "Find" function ? Thanks Tuk Edited November 28, 2006 by Tukata
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now