以文本方式查看主题

-  Foxtable(狐表)  (http://foxtable.com/bbs/index.asp)
--  专家坐堂  (http://foxtable.com/bbs/list.asp?boardid=2)
----  [求助]记录窗口提示问题  (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=74401)

--  作者:pcxjxjhkw
--  发布时间:2015/9/10 10:05:00
--  [求助]记录窗口提示问题

我在窗口中动态生成一SQLTable表,隐藏,绑定到记录窗口中,

想实现:1.记录窗口的标题可否设为右对齐,可否设置标题颜色?

2.鼠标移到记录窗口中的列中,自动以提示方式显示该内容?

 

谢谢


--  作者:大红袍
--  发布时间:2015/9/10 10:41:00
--  

1、

 

Dim rdg = e.Form.Controls("RecordGrid1").BaseControl

rdg.cols(0).TextAlign  = 7

rdg.cols(0).style.BackColor = color.Red

 

2、参考 http://www.foxtable.com/bbs/dispbbs.asp?BoardID=2&ID=72491&skin=0

 

 

-------全局代码
Public Sub MouseLeaveCell(sender As object, e As C1.Win.C1FlexGrid.RowColEventArgs)
    Functions.Execute("MouseLeaveCell", sender, e)
End Sub

Public Sub MouseEnterCell(sender As object, e As C1.Win.C1FlexGrid.RowColEventArgs)
    Functions.Execute("MouseEnterCell", sender, e)
End Sub

Public myToolTip As New Windows.Forms.ToolTip()

 

--------- 内部函数 MouseEnterCell
Dim sender As object = args(0)
Dim e As object = args(1)
myToolTip.SetToolTip(sender, sender(e.Row, e.Col))

 

-------- 内部函数 MouseLeaveCell
Dim sender As object = args(0)
Dim e As object = args(1)
myToolTip.SetToolTip(sender, "")

 

-------- 绑定事件
Dim g As C1.Win.C1FlexGrid.C1FlexGridBase = e.Form.Controls("RecordGrid1").baseControl
addhandler g.MouseEnterCell, addressof MouseEnterCell
addhandler g.MouseLeaveCell, addressof MouseLeaveCell


--  作者:pcxjxjhkw
--  发布时间:2015/9/10 10:47:00
--  
谢谢