this is first time i work with KendoUI and found there was no tutorial for my case.

I have a model:

public class SelectedDate{
     public DateTime BirthDay {get;set;}
}

First, i have a GET action as:

public ActionResult ShowDate(){
   return View(new SelectedDate());
}

on ShowDate.cshtml, i used a kendoUI named DatePicker as follow

@model SelectedDate

@(Html.Kendo().DatePickerFor(c => c.BirthDay ).Format("dd/MM/yyyy").Value(DateTime.Now))

and some button inside form

When i submit this form, model and data parsed into action successfully. But the BirthDay value always was {1/1/0001 12:00:00}

here my Action

[POST]
public ActionResult ShowDate(SelectedDate model){
       //model.BirthDay = {1/1/0001 12:00:00}
}

I tried too many way, but still incorrect. How can i find a solution ?

Related posts

Recent Viewed