Symplystyc Posted November 10, 2007 Posted November 10, 2007 is it possible to use _IELinkClickByText with a list of text? like if $list = list.txt _IELinkClickByText ($oIE, "list.txt") or something like that? The glass is neither half empty nor half full, it is simply twice as big as it needs to be.
Nahuel Posted November 10, 2007 Posted November 10, 2007 You mean you have a list of strings and you want to click them in an explorer one by one? Then you should look at: For..To..Next _FileCountLines() FileReadLine()
flyingboz Posted November 10, 2007 Posted November 10, 2007 is it possible to use _IELinkClickByText with a list of text? like if $list = list.txt _IELinkClickByText ($oIE, "list.txt") or something like that? Something like that how about -- for $i = 1 to $num_list_items $result = _IElink.....($ie,$list_item[$i]) if result is what we want , or if @error = 0 , or whatever, refer to the doc... then ExitLoop next essentially, you iterate through your options. Alternatively, you could make a really obnoxiously long if statement out of it, or any number of other ways to skin the cat. Reading the help file before you post... Not only will it make you look smarter, it will make you smarter.
Symplystyc Posted November 10, 2007 Author Posted November 10, 2007 (edited) Something like that how about -- for $i = 1 to $num_list_items $result = _IElink.....($ie,$list_item[$i]) if result is what we want , or if @error = 0 , or whatever, refer to the doc... then ExitLoop next essentially, you iterate through your options. Alternatively, you could make a really obnoxiously long if statement out of it, or any number of other ways to skin the cat. my fall back is the obnoxiously long if statement. I assume $list_item[$i] reffers to the i'th item in the list but what is $ie ( nvm got this part)? oh and i assume i have to have $list_item = something right? Edited November 10, 2007 by Symplystyc The glass is neither half empty nor half full, it is simply twice as big as it needs to be.
flyingboz Posted November 10, 2007 Posted November 10, 2007 let's say you have a list of items: $item_list = "apple pear orange" I can split these items into an array. $item_list = StringSplit($item_list," ") refer to the docs. $ie is my way of referring to $oIE, refer to the _IE.... help file. Remember, reading the helpfile doesn't just make you smarter, it makes you _look_ smarter! Reading the help file before you post... Not only will it make you look smarter, it will make you smarter.
Symplystyc Posted November 10, 2007 Author Posted November 10, 2007 let's say you have a list of items: $item_list = "apple pear orange" I can split these items into an array. $item_list = StringSplit($item_list," ") refer to the docs. $ie is my way of referring to $oIE, refer to the _IE.... help file. Remember, reading the helpfile doesn't just make you smarter, it makes you _look_ smarter! thanks again, i've been reading through the various functions and running them to see what they do. would this work for the item list $list_item = FileReadLine ( "members.txt" [, $i] ) Id like to just edit a text file for the list instead of entering everyting in the au3 file. one of my goals is to use _IELinkGetCollection to get a list of all the links on a page then to filter out all the links with the word userprofile into another list, this way I wouldnt have to manually add to a text file whenever a new link was added or removed. after that I'd need to add a check for multiple pages. also I"m having problems with _IEFormElementGetObjByName. I see how they did it with the google example but the page I'm looking at is written differently. off to read some docs. feel free to post more suggestions. The glass is neither half empty nor half full, it is simply twice as big as it needs to be.
Generator Posted November 10, 2007 Posted November 10, 2007 $oLinks = _IELinkGetCollection ($oIE) $iNumLinks = @extended For $oLink In $oLinks If StringInStr($oLink.herf,"http://www.autoitscript.com/forum/index.php?showtopic=") Then FileWrite($handle,$oLink.herf & @CRLF) Next
Symplystyc Posted November 10, 2007 Author Posted November 10, 2007 $oLinks = _IELinkGetCollection ($oIE) $iNumLinks = @extended For $oLink In $oLinks If StringInStr($oLink.herf,"http://www.autoitscript.com/forum/index.php?showtopic=") Then FileWrite($handle,$oLink.herf & @CRLF) Next perfect thanks for this. now I gotta look up what @extended means. The glass is neither half empty nor half full, it is simply twice as big as it needs to be.
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