Enters a a null reference (in Visual Basic Nothing) in the column.
[Visual Basic] Overrides Public Sub EnterNullValue() [C#] public override void EnterNullValue(); [C++] public: override void EnterNullValue(); [JScript] public override function EnterNullValue();
Enters the NullText value into the cell.
The following example tests a DataGridColumn to determine its column type. If the column is a TBD, and the DataColumn allows a null reference (Nothing) values, then the NullText property is set and the EnterNullValue method invoked.
[Visual Basic]
Private Sub SetNullText() Dim dgeCol As DataGridTextBoxColumn ' Assuming a column named Status exists.... Set dgeCol = DataGrid1.GridColumns("Status") If dgeCol.ToString = "DataGridTextBoxColumn" And dgeCol.DataColumn.AllowNull Then ' The NullText property is usually set in an initialization procedure. dgeCol.NullText = "Null Text" dgeCol.EnterNullValue End If End Sub
DataGridTextBoxColumn Class | DataGridTextBoxColumn Members | System.WinForms Namespace | Abort | Commit | Edit | NullText