none
how to: add controls to form after app is built..

Answers

  • Dim btn As Button = New Button()
    btn.Name = "newBtn"
    btn.Text = "New Button"

    Me.Controls.Add(btn)
    Thanks, A.m.a.L | [Remember to click "mark as answered" when you get a correct reply to your question]
    Sunday, April 26, 2009 8:13 PM

All replies

  • Dim btn As Button = New Button()
    btn.Name = "newBtn"
    btn.Text = "New Button"

    Me.Controls.Add(btn)
    Thanks, A.m.a.L | [Remember to click "mark as answered" when you get a correct reply to your question]
    Sunday, April 26, 2009 8:13 PM
  • no luck there.. this is what i have so far:

    Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
        Dim btn As Button = New Button()
        btn.Name = "newBtn"
        btn.Text = "New Button"
        btn.Location = New Point(331, 48)
        btn.Size = New Size(81, 90)
      End Sub




    Sunday, April 26, 2009 8:26 PM
  • Read AMAL's post again.
    Sunday, April 26, 2009 8:29 PM
  • Me.Controls.Add(btn)

    ahhhhhhhhhhhhhhhhh.. lol  
    Sunday, April 26, 2009 8:32 PM