“/”应用程序中的服务器错误。

该字符串未被识别为有效的 DateTime。

说明: 执行当前 Web 请求期间,出现未经处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。

异常详细信息: System.FormatException: 该字符串未被识别为有效的 DateTime。

源错误:


行 59: <%  string[]  ydArr= bs.Applicable.Split(','); %>
行 60:      <% foreach(string yd in ydArr){if(!string.IsNullOrEmpty(yd)){ %>    
行 61:      <a target="_blank" href="/cesuan/srmm-<%=Convert.ToDateTime("2015年"+yd).ToString("M-d") %>.htm"><%=yd +"," %>&nbsp;&nbsp;&nbsp;</a>
行 62:      <%}} %>
行 63: </div>  

源文件: e:\wwwrout\zhaoyuntang\www.zhaoyuntang.com\main\Views\CeSuan\Output\XingGeTeZheng.aspx    行: 61

堆栈跟踪:


[FormatException: 该字符串未被识别为有效的 DateTime。]
   System.DateTimeParse.Parse(String s, DateTimeFormatInfo dtfi, DateTimeStyles styles) +14154026
   System.Convert.ToDateTime(String value) +80
   ASP.views_cesuan_output_xinggetezheng_aspx.__Render__control1(HtmlTextWriter __w, Control parameterContainer) in e:\wwwrout\zhaoyuntang\www.zhaoyuntang.com\main\Views\CeSuan\Output\XingGeTeZheng.aspx:61
   System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +263
   System.Web.Mvc.ViewPage.Render(HtmlTextWriter writer) +76
   System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) +80
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3499


版本信息: Microsoft .NET Framework 版本:4.0.30319; ASP.NET 版本:4.6.1590.0