Initialize user aded row in a DataGridView

  • Thread starter Thread starter santi
  • Start date Start date
S

santi

Hi,

which is the standard way to initialize a typed dataset row with Guid
and DateTime columns when the user adds a new row in a bound
datagridView by clicking in the last row?

I can not set default values for some columns in the typed dataTable
because they are Guid's and DateTimes.
I can not do it in the rowChanged event either because before it fires
the datagridview throws an exception "The column xxx can not be null".

I am catching now the grid's UserAddedRow event, but It gives a
reference to the DataGridViewRow and I can't get the underlying row to
initialize it, so in the event I have to get the bindingSource.Current
object wich is the DataRow, but sometimes is not the added row!

thank you
 
Back
Top