if isdbnull(datareader.item("column_name")) then
' data not present
Not quite.
reader's IsDbNull() takes either the int column index or the string column name to test whether that value of that column is null for this row.
datareader.item("column_name") returns the data item (as an object) found at that named column. Obviously you shouldnt pass this to the IsDbNull() and Option Strict = on wont let you. If you code with Strict off (which you shouldnt ever do) then it will probably try to convert the object to a string which may return the value found, and then try to call the IsDbNull for that as the column name (which it is not
If youre confused, then heres an example:
Your datareader contains one column, FRUIT
This row right now, has the value "apple" in the FRUIT column
Your code will call:
if IsDbNull("apple")
When you need to call:
if reader.IsDbNull("FRUIT") ...
additionally, IsDbNull as a function on its own, is old VB (a legacy function implemented to help VB6 code work when pasted into .NET). Please use the new .NET functions in your code samples for newbies. You dont really help them by teaching them old VB..
Please test your code examples before you post them, or at least think carefully about what youre writing. Broken code is no use to anyone trying to learn