|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Dirty value of datagridview cellHow do I the value of a cell in a datagridview, before it is updated?
I wish to validate the "visible" value, not the actual value (cell/row hasn't been updated yet). Thanks in advance. /Snedker Hi,
Use the cell validating event Private Sub DataGridView1_CellValidating(ByVal sender As Object, ByVal e As System.Windows.Forms.DataGridViewCellValidatingEventArgs) Handles DataGridView1.CellValidating Dim strOld As String = DataGridView1.Item(e.ColumnIndex, e.RowIndex).Value.ToString Dim strNew As String = e.FormattedValue.ToString Trace.WriteLine(String.Format("Old Value {0} {1}New Value {2}", strOld, ControlChars.NewLine, strNew)) End Sub Ken -------------------- Show quoteHide quote "Morten Snedker" <morten_spammenot_ATdbconsult.dk> wrote in message news:di9222tqtcqvn1is7magvga42smv1fjq55@4ax.com... > How do I the value of a cell in a datagridview, before it is updated? > > I wish to validate the "visible" value, not the actual value (cell/row > hasn't been updated yet). > > > Thanks in advance. > > /Snedker
Decimal/Single/...: which Numeric-type to use?
Sorting a System.Collections.ObjectModel.Collection Converting vb.net book examples Process.Start() throws an error saying "Setup error: failed to load resources from resource file Ple ot: mvps, how do you propse one? Creating a CSV from query results Sending emails to multiple recipients ADO RowState problem AddressOf from VB6 to .Net VB MouseUp event fires randomly on Listview |
|||||||||||||||||||||||