请教老师:
1、窗口的table的选定区域的默认背景色可以设置吗?不要UseVisualStyle ,这会改变表格的立体化的表头;
2、我用如下程序临时标注了下背景色后,再取消后,选定区域的背景色竟然不着色了,何解?
Dim r As Row=args(0)
Dim cs1 As C1.Win.C1FlexGrid.CellStyle= Tables("主窗口表").grid.Styles.Add("选中样式")
cs1.foreColor =Color.red
cs1.backColor =Color.Khaki
Dim cs2 As C1.Win.C1FlexGrid.CellStyle= Tables("主窗口表").grid.Styles.Add("未选样式")
cs2.foreColor =Color.black
cs2.backColor =Color.white
For Each c As Col In r.Table.Cols
If r.Checked Then
r.Table.Grid.SetCellStyle(r.Table.HeaderRows+r.Index,c.Index+1,cs1)
Else
r.Table.Grid.SetCellStyle(r.Table.HeaderRows+r.Index,c.Index+1,cs2)
End If
Next