How to do - MS SQL C# Excel Access
Tuesday, 7 January 2014
C# - How to fix error The name 'DbNull' does not exist in the current context
Replace
if (row["ID"] != DbNull.value)
{
myID = (int)row["ID"];
}
with
if (row["ID"] != null)
{
myID = (int)row["ID"];
}
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment