Results 1 to 5 of 5

Thread: control array

  1. #1

    Thread Starter
    Member
    Join Date
    Jun 2006
    Location
    Heaven
    Posts
    39

    control array

    is it possible to creat a dynamic control array

  2. #2

    Thread Starter
    Member
    Join Date
    Jun 2006
    Location
    Heaven
    Posts
    39

    Re: control array

    Please any expert Help me

  3. #3
    Raging swede Atheist's Avatar
    Join Date
    Aug 2005
    Location
    Sweden
    Posts
    8,018

    Re: control array

    What do you mean by dynamic? Do you want to be able to remove and add controls during runtime? Then you should go for a List(Of T).

    For example, if you're looking to populate it with textboxes you'd declare it like so:

    C# Code:
    1. List<TextBox> textBoxList = new List<TextBox>();

    Adding and removing textboxes is just as easy as using the Add/Remove methods.
    Rate posts that helped you. I do not reply to PM's with coding questions.
    How to Get Your Questions Answered
    Current project: tunaOS
    Me on.. BitBucket, Google Code, Github (pretty empty)

  4. #4

    Thread Starter
    Member
    Join Date
    Jun 2006
    Location
    Heaven
    Posts
    39

    Re: control array

    thanks sir, yes you are right, please guide me how to use it.

  5. #5
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: control array

    Lookup the List<T> class in the MSDN Library. That will guide you how to use it.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width