hi, I have a datagrid that contain a date field. if the field has a adate before I update the row, it make the update, but if a edit a record that has no date in the column field, I get the following error, any idea how to fix it.
thanks Al
Cast from type 'DBNull' to type 'Date' is not valid.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.InvalidCastException: Cast from type 'DBNull' to type 'Date' is not valid.
Source Error:
Line 64: vinitialcontact =dr("initialcontact")
Line 65: vfollowup= dr("followup")
Line 66:vnextfollowupdate = dr("nextfollowupdate")
Line 67:end while
thanks Al
Cast from type 'DBNull' to type 'Date' is not valid.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.InvalidCastException: Cast from type 'DBNull' to type 'Date' is not valid.
Source Error:
Line 64: vinitialcontact =dr("initialcontact")
Line 65: vfollowup= dr("followup")
Line 66:vnextfollowupdate = dr("nextfollowupdate")
Line 67:end while