I'm trying to handle null values in a field that are causing the following error:
Cast from type 'DBNull' to type 'String' is not valid
I've tried variations on this:
Me.txtTextBox.Text = IIF(IsNull(dr("FieldName")),"",dr("FieldName"))
But get build errors stating that IsNull is not declared.
How do I check for nulls?
(VB.Net 2003, SQL Server back end)