GetFontColor
GridCell.GetFontColor method
获取单元格字体颜色。 更改颜色时,应调用“SetFontColor”方法, 设置单元格字体颜色。
public Color GetFontColor()
返回值
返回单元格字体颜色。
例子
[C#]
GridCell cell = gridDesktop1.GetActiveWorksheet().Cells[0, 0];
Font font = new Font("Courier New", 8, FontStyle.Italic);
cell.SetFont(font);
Color color = cell.GetFontColor();
color = Color.Black;
cell.SetFontColor(color);
[Visual Basic]
Dim cell As GridCell = gridDesktop1.GetActiveWorksheet().Cells(0, 0)
Dim font As Font = New Font("Courier New",8,FontStyle.Italic)
cell.SetFont(font)
Dim color As Color = cell.GetFontColor()
color = Color.Black
cell.SetFontColor(color)