C# 提示 按纽
来源:百度知道 编辑:UC知道 时间:2024/06/14 12:51:13
可以的
添加一个tooltip控件到窗体,然后你就会看到其他控件属性里面有一个tooltip属性了。
.net环境里似乎是没有这个属性了,要的话要弄个Tooltip控件。
//ToolTip m_tooltip = new ToolTip();
//m_tooltip.AutoPopDelay = 5000;//display 5s.
//m_tooltip.InitialDelay = 100;//after 1s the tooltip will show.
//m_tooltip.ReshowDelay = 100;//reshow time.
//m_tooltip.ShowAlways = true;//active or not ,it always show.
//m_tooltip.IsBalloon = true;//change the style to balloon.
//m_tooltip.ToolTipIcon = ToolTipIcon.Warning;//set the icon.
//m_tooltip.ToolTipTitle = "Hello";//set the caption
//m_tooltip.UseAnimation = true;
//m_tooltip.SetToolTip(this.button1, "This is caption");//set which control to show this balloon.
private void Form1_Load(object sender, EventArgs e)