C#渐变窗体(让窗体慢慢出现)
【转载】
public partial class Form1 : Form { public Form1() { InitializeComponent(); } private void timer1_Tick(object sender, EventArgs e) { if (this.Opacity > 0.1) { this.Opacity = this.Opacity - 0.02; } else { this.timer1.Enabled = false; Close(); } } private void Form1_Load(object sender, EventArgs e) { this.timer1.Enabled = true; this.Opacity = 0.99; } }