mr_unreliable Posted September 19, 2005 Posted September 19, 2005 hi gang, I would like to pick out a specific item from a collection. I tried the emum items capability and it works fine, i.e., For $Match In $Matches ; (for each) loop through the $Matches collection ... Next To go one step further, in vbScript, it is possible to pick out an individual item like this: $Matches(1).Value That is vbs shorthand for specifying a specific item like this: $Matches.Item(1).Value Both of these syntaxes work in vbs, but I couldn't get either to work in au3b. Note: I also tried square brackets, which didn't work either. Am I missing something, or is it not possible to address an individual item in a collection??? tiafah, jw
seandisanti Posted September 19, 2005 Posted September 19, 2005 hi gang,I would like to pick out a specific item from a collection.I tried the emum items capability and it works fine, i.e.,For $Match In $Matches ; (for each) loop through the $Matches collection...NextTo go one step further, in vbScript, it is possible to pick outan individual item like this:$Matches(1).ValueThat is vbs shorthand for specifying a specific item like this:$Matches.Item(1).ValueBoth of these syntaxes work in vbs, but I couldn't get eitherto work in au3b. Note: I also tried square brackets, which didn't work either.Am I missing something, or is it not possible to address anindividual item in a collection???tiafah, jwpersonally i don't use collections much, i prefer arrays....you could easily create an array and add the items of the collection to the array, so that they could be referenced by index.
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