关于给控件加一个ToolTip提示

时间:2013-06-29 04:35:11
【文件属性】:
文件名称:关于给控件加一个ToolTip提示
文件大小:22KB
文件格式:ZIP
更新时间:2013-06-29 04:35:11
c# When you add a ToolTip control to a form, it is active by default. Therefore, you do not have to do anything to make it active. If you look at the source file for your form, you will see code that looks something like as follows. Collapse Copy Code private System.WinForms.ToolTip m_wndToolTip; this.m_wndToolTip = new System.WinForms.ToolTip (this.components); m_wndToolTip.SetToolTip (PictureButton, "Click Me!"); m_wndToolTip.SetToolTip (m_wndIntTextBox, "Enter Integer data type value.");The SetToolTip method associates ToolTip text with the given control. If you wish to deactivate the ToolTip control, simply set the Active property to false. Collapse Copy Code m_wndToolTip.Active = false;The attached demo project contains a simple form with two edit controls. One is for entering double type data and second is for entering integer type data. When you move the mouse over these controls, the tooltips for the corresponding controls will be displayed.
【文件预览】:
NetGUIUtils
----NetGUIGoodies()
--------NetGUIGoodies_Release.projdata(3KB)
--------NKStringUtil.cs(2KB)
--------AssemblyInfo.cs(2KB)
--------NKBitmapButton.cs(2KB)
--------NKNumericTextBox.cs(4KB)
--------NetGUIGoodies.csproj(4KB)
--------NetGUIGoodies.csproj.user(1KB)
--------NetGUIGoodies_Debug.projdata(8KB)
----NetGUIUtils.suo(9KB)
----NetGUITabsTest()
----NetGUITest()
--------NetGUITest_Debug.projdata(3KB)
--------WinkyMe.bmp(1KB)
--------TestForm.cs(6KB)
--------NetGUITest.csproj.user(1KB)
--------NetGUITest.csproj(5KB)
--------AssemblyInfo.cs(2KB)
--------TestForm.resx(32KB)
--------SmileyMe.bmp(1KB)
--------NetGUITest_Release.projdata(3KB)
--------WeepyMe.bmp(1KB)
----NetGUIUtils.sln(2KB)

网友评论

  • 不能用 骗积分