NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

DataRow.IsNull (DataColumn)

Gets a value indicating whether the specified DataColumn contains a null value.

[Visual Basic]
Overloads Public Function IsNull( _
   ByVal column As DataColumn _
) As Boolean
[C#]
public bool IsNull(
   DataColumn column
);
[C++]
public: bool IsNull(
   DataColumn* column
);
[JScript]
public function IsNull(
   column : DataColumn
) : Boolean;

Parameters

column
[To be supplied.]

Return Value

true if the column contains a null value; otherwise, false.

Example [Visual Basic]

The following example prints each column of each row in each table of a DataSet. If the row is set to a null value, the value is not printed.

[Visual Basic]

Private Sub PrintRows(ds As DataSet)
   Dim t As DataTable
   Dim dc As DataColumn
   Dim r As DataRow
   For Each t In ds.Tables
      For Each r In t.Rows
         For Each c In t.Columns
If Not r.IsNull(c) Then Console.WriteLine(r(c)).ToString
         Next c
      Next r
    Next t
End Sub

See Also

DataRow Class | DataRow Members | System.Data Namespace | DataRow.IsNull Overload List