C# winform基础 1、Timer不起作用 2、 设置图片透明

时间:2017-01-19 12:38:45   收藏:0   阅读:311

1、设置图片透明

 

this.pibox.BackColor = System.Drawing.Color.Transparent;  //将背景设置为透明
this.pibox.Parent = lab_show;  //将父容器设置为上一层的文件名

 

 

 

2、Timer不起作用

1、先托控件Timer,

并做相关设置 

this.timerpic.Interval = 4000;
this.timerpic.Tick += new System.EventHandler(this.timerpic_Tick);

2、将要处理内容放到this.timerpic_Tick事件中

private void timerpic_Tick(object sender, EventArgs e)
{
pibox.Hide();
}

 

3、启用timerpic

timerpic.Enabled = true;

原文:http://www.cnblogs.com/cuozhixu/p/6305949.html

评论(0
© 2014 bubuko.com 版权所有 - 联系我们:wmxa8@hotmail.com
打开技术之扣,分享程序人生!