誰能告訴我什麼VB相當於這個是請:VB轉換爲C#剃刀語法 - MVC
@model DateTime
Using Date Template
@Html.TextBox("", String.Format("{0:d}", Model.ToShortDateString()),
new { @class = "datefield", type = "date" })
我想:
@model DateTime
使用日期模板
@Html.TextBox("", String.Format("{0:d}", Model.ToShortDateString()), New With {Key .class = "datefield", Key .type = "date"})
...但錯誤發生在: NullReferenceException未被用戶代碼處理 Obj ect變量或未設置塊變量。
這是從教程:Using the HTML5 and jQuery UI Datepicker Popup Calendar with ASP.NET MVC - Part 4