nirklir Posted March 14, 2011 Share Posted March 14, 2011 hello again to all helpers,I have a bit more complicated question to ask,I need to retrieve a word from an HTML page, it looks like this:<tr style="color......"> <td class="filelink" style="...."<a href="javascript....." style="...">33333</a></td><td>texttocopy</td>.......... so onI have the number 333333 , and i need to retrieve the text that comes after it : "texttocopy"ALOT of thanks,nir Link to comment Share on other sites More sharing options...
Xenobiologist Posted March 14, 2011 Share Posted March 14, 2011 Try _StringBetween. Scripts & functions Organize Includes Let Scite organize the include files Yahtzee The game "Yahtzee" (Kniffel, DiceLion) LoginWrapper Secure scripts by adding a query (authentication) _RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...) Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc. MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times Link to comment Share on other sites More sharing options...
nirklir Posted March 14, 2011 Author Share Posted March 14, 2011 Try _StringBetween.you mean that i should grab all the text in the html , and then check between ('33333','<td>') ? Link to comment Share on other sites More sharing options...
Xenobiologist Posted March 14, 2011 Share Posted March 14, 2011 Yep, that should do the trick. Scripts & functions Organize Includes Let Scite organize the include files Yahtzee The game "Yahtzee" (Kniffel, DiceLion) LoginWrapper Secure scripts by adding a query (authentication) _RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...) Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc. MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times Link to comment Share on other sites More sharing options...
Carlo84 Posted March 14, 2011 Share Posted March 14, 2011 Try avoiding to use that on the entire html. it might take a long time dependng on how long the html is. if you downloaded the source you could filereadline() untill stinginstr() for 33333 is diffrent then 0 or try to split the html string. Its a lil more work to code, but it will go faster. _SplashProgressImage | _Regionselector | _IsPressed360 | _UserAccountContol_SetLevel | _ListSubFolders Link to comment Share on other sites More sharing options...
DaleHohm Posted March 15, 2011 Share Posted March 15, 2011 You may also find that _IETableWriteToArray may give you what you need. Dale Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model Automate input type=file (Related) Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better? IE.au3 issues with Vista - Workarounds SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead? Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble Link to comment Share on other sites More sharing options...
Shaarad Posted March 15, 2011 Share Posted March 15, 2011 I think StringInStr, StringTrimRight, StringTrimLeft, StringLen will be the important set of commands for this... Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
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