By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,296 Members | 1,472 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,296 IT Pros & Developers. It's quick & easy.

Disable DataGridView cell highlighting

P: n/a
I have Text box controls and DataGridView control in WinForms form.

DataGridview contains custom ComboBox columns and standard TextBox columns.
Edit mode is EditOnEnter.

When focus is moved out of DataGridView, its current cell is displayed as
selected state (blue background).

How to remove this highlight so that selected cell is not highlighted at all
(or highlighted only when grid is active control).

Andrus.
Mar 24 '08 #1
Share this Question
Share on Google+
1 Reply


P: n/a
On the DefaultCellStyle for the grid, set the SelectionBackColor to the same
color as the BackColor for the cell.

RobinS.

"Andrus" <ko********@hot.eewrote in message
news:u5**************@TK2MSFTNGP02.phx.gbl...
>I have Text box controls and DataGridView control in WinForms form.

DataGridview contains custom ComboBox columns and standard TextBox
columns. Edit mode is EditOnEnter.

When focus is moved out of DataGridView, its current cell is displayed as
selected state (blue background).

How to remove this highlight so that selected cell is not highlighted at
all (or highlighted only when grid is active control).

Andrus.
Mar 27 '08 #2

This discussion thread is closed

Replies have been disabled for this discussion.