1, foreground method
Just set the forecolor to the desired color, in this case red.
& ltdatagridview? ForeColor= "red"? /& gt; 2. Background method
You need to name datagridview first. Just set the forecolor to the desired color, in this case red.
datagridview? datagridview 1=new? datagridview();
dataGridView 1。 Foreground? =? Color. Red;