Server Error in '/' Application.

String was not recognized as a valid DateTime.

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.FormatException: String was not recognized as a valid DateTime.

Source Error:


Line 49:             basvuru = _dr["course_rec"].ToString();
Line 50:             kota = _dr["course_quota"].ToString();
Line 51:             baslangictarih = Convert.ToDateTime(_dr["course_rec_start_date"].ToString());
Line 52:             bitiştarih = Convert.ToDateTime(_dr["course_rec_end_date"].ToString());
Line 53:             Literal1.Text = baslik;

Source File: c:\wwwroot\users\dernek\rmcd.org.tr\CourseReg.aspx.cs    Line: 51

Stack Trace:


[FormatException: String was not recognized as a valid DateTime.]
   System.DateTimeParse.Parse(String s, DateTimeFormatInfo dtfi, DateTimeStyles styles) +14545182
   System.Convert.ToDateTime(String value) +80
   CourseReg.Page_Load(Object sender, EventArgs e) in c:\wwwroot\users\dernek\rmcd.org.tr\CourseReg.aspx.cs:51
   System.Web.UI.Control.OnLoad(EventArgs e) +106
   System.Web.UI.Control.LoadRecursive() +68
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3785


Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.7.4087.0