Home > Software engineering >  C# Forms - remove column header in DataGridView
C# Forms - remove column header in DataGridView

Time:11-01

(sorry for links, not allowed to post images)

I have a 10x10 datagridview with images (black squares are images) in each grid.

I have a weird row at the top with a null image icon at the top.

https://i.stack.imgur.com/PNnbr.png

I have made inivisble all column and row headers in the properties

https://i.stack.imgur.com/R84v3.png https://i.stack.imgur.com/xCzHn.png

10 Columns, all the same settings as the one showed: https://i.stack.imgur.com/Ghxdj.png

The code to add the images in each row.

https://i.stack.imgur.com/xd12A.png

CodePudding user response:

Clear the grid before adding rows:

this.gridMachines.Rows.Clear();

CodePudding user response:

Damn yeah it's a row... How did I not think of that. Thought it was a column header for some reason. Thank you!

  • Related