|
-
Aug 18th, 2005, 01:21 PM
#5
Re: [RESOLVED] For Each with custom collection class
what if I didn't have a collection variable and was instead doing it manually.
For...Each works on arrays as well. Not sure I understand what you mean by "doing it manually".
Does the NewEnum method return the next item in the collection each time it is called?
Yes.
If so, what does it return when you run out of items?
The For...Each loop just exits. You would need the code the "Compiler" generates to figure out how it implements For...Each. As to what it returns, most likely Null or Nothing.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|