G
Guest
Hi everyone,
I've got a class with some strings an datetime fields.
When I set the values of all the members of the class with a datareader,
I've got an error on the DateTime field, which must be NULL.
myAddress.Birthday = DateTime.Parse(drAddress["Birthday"].ToString());
When the Birthday column is NULL in the database, I've got an error.
NULL can't be converted to DateTime.
what is the solution to this problem?
thanks!
Filip
I've got a class with some strings an datetime fields.
When I set the values of all the members of the class with a datareader,
I've got an error on the DateTime field, which must be NULL.
myAddress.Birthday = DateTime.Parse(drAddress["Birthday"].ToString());
When the Birthday column is NULL in the database, I've got an error.
NULL can't be converted to DateTime.
what is the solution to this problem?
thanks!
Filip