Tag Archives: custom form background color
Winforms by default don’t offer much customization as far as coloring, especially when it comes down to gradient patterns.
If you want to change the background of your form to something a bit more unique to make it look like this
First handle the form’s
private void Form1_Paint(object sender, PaintEventArgs e)
Graphics g = e.Graphics;
Rectangle rect = new Rectangle(0, 0, this.Size.Width, this.Size.Height);
LinearGradientBrush brush = new LinearGradientBrush(rect, Color.Green, Color.White, LinearGradientMode.ForwardDiagonal);
Feel free to change the colors and the gradient direction to what you would like.