Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. creating control arrays in vb.net

creating control arrays in vb.net

Scheduled Pinned Locked Moved Visual Basic
csharpdata-structuresquestion
3 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    chathu03j
    wrote on last edited by
    #1

    how do you create a control array in vb.net?

    Z C 2 Replies Last reply
    0
    • C chathu03j

      how do you create a control array in vb.net?

      Z Offline
      Z Offline
      zacharyshroyer
      wrote on last edited by
      #2

      You can't create them like you did in vb6. The controls all have to have unique names, but you can have multiple controls use the same event code. Let's say you have three text boxes. TextBox1 TextBox2 TextBox3 You can set it up for all of them to use the same event code like: Private Sub TextBox_TextChanged(ByVal sender As System.Object, _ ByVal e As System.EventArgs) Handles TextBox1.TextChanged, _ TextBox2.TextChanged, _ TextBox3.TextChanged 'do some common processing here End Sub

      1 Reply Last reply
      0
      • C chathu03j

        how do you create a control array in vb.net?

        C Offline
        C Offline
        chat_sp2001 yahoo com
        wrote on last edited by
        #3

        Dim alist As New ArrayList Here we have to create the object of the control and then u add the contol to the array if u have any doubt see this link http://www.devx.com/vb2themax/article/19907 alist.Add(aControl)

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups