Home > Code > C# > Dynamically create controls in c# windows application

Dynamically create controls in c# windows application

by John Prathip   on Nov 24, 2015   Category: C#   |  Views: 853    |  Points: 25   |  Silver 


private void Merging_Load(object sender, EventArgs e)
{
Button button = new Button();
button.Location = new System.Drawing.Point(30,90);
button.Size = new System.Drawing.Size(180,35);
button.Text = "Submit";
button.Name = "btnSubmit";
button.Click += new EventHandler(Data_Merging_ButtonClick);
this.Controls.Add(button);
}

private void Data_Merging_ButtonClick(object sender, EventArgs e)
{

}


Post Code  |  Code Snippet Home

Recent Posts

User Responses


No response found, be the first to review this code snippet.

Submit feedback about this code snippet

Please sign in to post feedback

Latest Posts