Visual Basic 2003 Web App. This code fires from select column on datagrid. When fired the row from datagrid is copied to sql 2000 table. Everything was working until the field was left null. It's not an option to make the field required forcing the user to enter a date.
Dim rinsertCommand As SqlCommand = New SqlCommand
rinsertCommand.Connection = SqlConnection1
rsql = "insert into reschedulehistory(ReqShipDate)
rinsertCommand.CommandText = rsql
rinsertCommand.Parameters.Add("@ReqShipDate", System.Data.SqlDbType.DateTime).Value = DateTime.Parse(colreqshipdate)
I get this error: The string was not recognized as a valid DateTime. There is a unknown word starting at index 1
I can paste all the code if you like.