如何把鼠标移到一个SLE控件上面后 会闪出一个提示信息 提示这个SLE框中输入内容的要求!
假如:我要求在这个SLE控件下面只能输入数字!我要怎么做 才能在鼠标移到SLE上面后会提示输入要求?请高手指点 谢谢
------解决方案--------------------
保存为uo_singlelineedit.sru,然后导入pbl中
- C/C++ code
$PBExportHeader$uo_singlelineedit.sruforwardglobal type uo_singlelineedit from singlelineeditend typeend forwardglobal type uo_singlelineedit from singlelineeditinteger width = 530integer height = 100integer textsize = -9integer weight = 400fontcharset fontcharset = gb2312charset!fontpitch fontpitch = variable!string facename = "宋体"long textcolor = 33554432string text = "none"borderstyle borderstyle = stylelowered!event ue_mousemove pbm_mousemoveend typeglobal uo_singlelineedit uo_singlelineedittype variablespublic:integer tipicon = 0 //提示框显示的图标:TTI_NONE=0,TTI_INFO=1,TTI_WARNING=2,TTI_ERROR=3string tiptitle = '' //提示框显示的标题rowfocusind Tooltiptype = hand! //提示框显示类型:hand! 为气泡型提示框, focusrect! 为方框型提示框, off!为不显示private:nvo_tooltips invo_tooltipint i_uidend variablesevent ue_mousemove;invo_tooltip.of_relaymsg( this, 512) //512代表鼠标移动是显示tooltipend eventon uo_singlelineedit.createend onon uo_singlelineedit.destroyend onevent constructor;invo_tooltip.of_set_tippro( tipicon, tiptitle, TOOLTIPTYPE)i_uid = invo_tooltip.of_addtool( this, this.tag, 0) //以控件的tag属性为tip内容end event