DataGridView

DataGridView

I’ve been working a lot lately with the DataGridView.  One instance of a DataGridView would refuse to be editable even though I checked all the relevant settings (Enabled, EditMode, ReadOnly, RowTemplate.ReadOnly, Columns.ReadOnly).   I had previously missed the RowTemplate.ReadOnly setting  and had it working once I set it to false, but then it stopped working again.  I found that removing the set property for the data members that were specified in the Column Properties DataPropertyName value, was the reason it stopped working.  Kinda makes sense but I wish there was better feedback from VisualStudio to alert me of the mismatched settings.

Leave a Reply