Casting dynamically created button text in a dynamically created textbox in

Last Reply 8 days ago By dharmendr

Posted 14 days ago

I dynamically create button at runtime using a button.


  Dim btn As Button = New Button()
        btn.BackColor = Color.DarkGray
        btn.Height = 21
        btn.Width = 35
        btn.Text = TextBox1.Text
        Dim txt As TextBox = New TextBox()

        txt.Height = 21
        txt.Width = 35

I want if I click on any of the textbox to get focus and then click on any of the created button, the text on the button will appear in that textbox.

You are viewing reply posted by: dharmendr 8 days ago.