老师:
我按照以下代码设置样式,但是字体颜色以及背景颜色的代码好像不起作用,没有起到着色效果。
第一步:增加自定义样式With e.Form.Controls("Table1").Table.DataTable
.AddUserStyle("自定义", Color.White , Color.DarkGray) End With
第二步:写表DrawCell事件
select case e.col.name
case "A"
If e.Row.IsNull("A")= true then
If e.Row.Index = e.Table.RowSel Then
e.Style ="自定义"
e.text="在这里替换提示信息..."
End If
End If
end select