Rss & SiteMap
Foxtable(狐表) http://www.foxtable.com
方法一:drawcell事件
If e.Col.Name = "第一列" Then
e.StartDraw()
Dim msg As String=e.Text
Dim tl As Integer = e.Text.Length
Dim w As Integer = e.Width -4
Dim h As Integer = e.Height-4
Dim x As Integer = e.x + (e.Width - w)/2
Dim n As Pen
Dim fnt As New Font("楷体",9,FontStyle.Bold)
Dim br As Brush
n = New Pen(Color.Green,2)
br = New SolidBrush(color.Green)
Dim sf As new StringFormat
sf.Alignment = StringAlignment.Center
sf.LineAlignment = StringAlignment.Center
e.Graphics.DrawRectangle(n,x,e.y + 2,w,h)
e.Graphics.DrawString(msg,fnt,Brushes.black, new Rectangle(e.x, e.y, e.width, e.height), sf)
e.Text = ""
e.EndDraw()
End If
方法二:
Tables("表A").Grid.cols("第二列").Style.Border.Style = 2
Tables("表A").Grid.cols("第二列").Style.Border.width = 2
Tables("表A").Grid.cols("第二列").Style.Border.Color = Color.red