I'm developing a Windows Form C # activity control application for a company, however I would need to display the activities as buttons within the GridView
cell.
I've tried:
DataGridViewButtonColumn uninstallButtonColumn = new DataGridViewButtonColumn();
uninstallButtonColumn.UseColumnTextForButtonValue = true;
uninstallButtonColumn.HeaderText = "Delete/Edit";
uninstallButtonColumn.Name = "uninstall_column";
uninstallButtonColumn.Text = "Teste";
dgvPrincipal.Columns.Insert(1, uninstallButtonColumn);
This format allows only 1 button, when in fact there may be several buttons in the same cell.
And I've tried it too:
dgvPrincipal.Rows[0].Cells[0].DataGridView.Controls.Add(tbnTeste);
This inserts the button without any link with the cells.
Does anyone know a way? Type DataRowBound
... or something similar?