DataGridView の CellFormatting でcellの色を設定しているのですが、
設定の仕方によって、設定後の色の取得ができたりできなかったりします。
できない場合にどうして色が取得できないのか、分かる方いますか?


■色の取得ができる場合
private void DataGridView1_CellFormatting(object sender, DataGridViewCellFormattingEventArgs e)
{
DataGridView dgv = (DataGridView)sender;
dgv[e.ColumnIndex, e.RowIndex].Style.BackColor = Color.Orange;
}

↑実行後に別メソッドで↓

DataGridViewCell cell = (色を変えたセル)
if (cell.Style.BackColor.Equals(Color.Orange)){...} ★trueになる


■色の取得ができない場合
private void DataGridView1_CellFormatting(object sender, DataGridViewCellFormattingEventArgs e)
{
e.CellStyle.BackColor = Color.Orange;
}

↑実行後に別メソッドで↓

DataGridViewCell cell = (色を変えたセル)
if (cell.Style.BackColor.Equals(Color.Orange)){...} ★falseになる

cell.Style.BackColorをデバッガで見ても、何も設定されてない → "{Name=0, ARGB=(0, 0, 0, 0)}"
でもGUI上は確かに色が変わっている