Top "Datagridview" questions

DataGridView is a Windows Forms control used to display and edit tabular data.

What is the fastest way to export dataGridView rows to Excel or into an SQL Server database

What is the fastest way to export DataGridView rows in the range of 460328 - 800328 to Excel or into an SQL …

c# datagridview streamwriter
"BindingSource cannot be its own data source" - error when trying to reset the binding source from a method in another class

We are binding a DataGridview using BindingSource. So in the main thread we have given like this. class1BindingSource = new …

winforms datagridview thread-safety backgroundworker bindingsource
sometimes I want to hide buttons in a DataGridViewButtonColumn

I have a DataGridView which was the subject of a previous question (link). But sometimes the Button is null. This …

c# datagridview visibility datagridviewbuttoncolumn
How to switch between DataGridViewTextBoxCell and DataGridViewComboBoxCell?

I want to have a DataGridView that has two columns. The first column will always be of type DataGridViewComboBoxColumn. Based …

vb.net visual-studio-2005 datagridview datagridviewcomboboxcell datagridviewtextboxcell
Is there a way to force a DataGridView to fire its CellFormatting event for all cells?

We use the CellFormatting event to colour code cells in various grids all over our application. We've got some generic …

winforms datagridview cell-formatting
How to identify dataGridView cell that was right clicked on for ContextMenuStrip?

User right clicks on a cell within a DGV, then makes a selection in the ContextMenuStrip. Based on their CMS …

c# visual-studio-2010 datagridview contextmenustrip
Why it doesn't save changes into datatable from datagridview?

I have binded datagridview with datatable (Growns). My main goal is, that user can work with datagridview (dataGridView1), filling and …

c# winforms datagridview datatable dataadapter
Getting "Index was out of range" exception in DataGridView when clicking header

I am using a DataGridView to display my data from a SQLite database. One column is a directory to open …

c# winforms datagridview indexoutofrangeexception
How to bind DataGridViewComboBoxColumn to a OnChange event (C#)

I have a standard DataGridView, and my last column is a DataGridViewComboBoxColumn. I would like to add an event so …

c# events datagridview datagridviewcombobox
Finding datagridview cell type in C#?

i am trying to find each DatagridviewImageCell and set its property ImageLayout to DataGridViewImageCellLayout.Zoom so the image in that …

c# winforms datagridview visual-c#-express-2010