private void Form1_Load(object sender, EventArgs e) { button1.Width = 50; // set your default width button1.Height = 50; // set your default height } private void button1_MouseEnter(object sender, EventArgs e) { Button button = (sender as Button); button.Width = 100; // set the width to increase on mouse hover button.Height = 100;// set the height to increase on mouse hover } private void button1_MouseLeave(object sender, EventArgs e) { Button button = (sender as Button); button.Width = 50; // set to default width button.Height = 50; // set to default height }
{ button1.Width = 50; // set your default width button1.Height = 50; // set your default height }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)