I am making a Windows Forms application. I want the forms height to increase after a button is pressed. How do I do this?
Use the Height
property. For instance:
this.Height = newHeight;
You can just increase the form height value by a specified amount on the button click:
private void button1_Click(object sender, EventArgs e)
{
int amountToIncrease = 10;
this.Height += amountToIncrease;
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With