When designing data tables in the .xsd designer in Visual Studio, there is a property that specifies what to do when the table encounters a null value:

screenshot

The problem is, if the DataType is System.DateTime, I'm unable to return empty or nothing. It always throws an exception.

As I work around, I can do the following:

<!-- language: lang-vb -->
If(row.IsDateLastRecallPrintedNull, DateTime.MinValue, row.DateLastRecallPrinted)

But if the value is DbNull.Value, I'd rather just have it return that.

Using IsDateLastRecallPrintedNull isn't a workaround, it's the way it's intended to be used. If you use a nullable date, you can set this to nothing rather than DateTime.MinValue in your code. Alternatively you can change the datatype in the dataset to System.Object, and then you can select '(Nothing)' in the dropdown. Note that you can overtype the NullValue entry in the properties with another value that's appropriate for the data type, although it won't work if you enter DateTime.Minvalue - it'll appear to accept it, but then fail - but you can put in another magic number such as 01/01/1900.

All this is 'by design'.*

Using databinding sidesteps this quagmire to a great extent; if you're reading programmatically from the dataset then IsxxxNull is the way to go.

*I suspect this is too often a Microsoftism for 'we didn't finish it by ship date'