僅來自TextBoxFor()的日期我無法使用TextBoxFor <,>(表達(dá)式,htmlAttributes)將DateTime的唯一日期部分顯示到文本框中。該模型基于Linq2SQL,字段是SQL上的DateTime和實(shí)體模型。失?。?lt;%= Html.TextBoxFor(model => model.dtArrivalDate, String.Format("{0:dd/MM/yyyy}", Model.dtArrivalDate))%>這個技巧似乎被折舊了,對象htmlAttribute中的任何字符串值都被忽略了。失?。篬DisplayFormat( DataFormatString = "{0:dd/MM/yyyy}" )]public string dtArrivalDate { get; set; }我想在詳細(xì)信息/編輯視圖中存儲和顯示日期部分,而不是“00:00:00”部分。
僅來自TextBoxFor()的日期
慕的地8271018
2019-08-26 09:30:07