|
-
Jul 31st, 2002, 08:53 AM
#1
Requested Tip - Control Arrays?!
Ok Im going to nip this one in the bud. This is asked alot. Yes Control Arrays are still there in a sense. You just dont have the Index property anymore. You can add a control to a regular array or arraylist.
BUT>>>>>>>>>
Here is the problem. Dont do it. Why? Becuase when a control is created, it is added to a Collection of controls. You can enumerate through the controls in this collection to do what you need or add to it dynamically. So why waste resources on yet another 'collection'(the array) to do things the old way. It is best in thethis regard to grin and bare it, and learn how to work with collections and control collections.
You also have a groupbox control thats you can use as a container for controls you may want to seperate from the main controls collection.
Now I dont have any code as of yet because I just havent had to do any of this yet, but I have been reading up on it. Anyone else who wants to shed some more light here is welcome to.
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
|