Set date format to dd MMM yyyy in Custom Editor Template

2 posts, 0 answers
  1. Benjamin
    Benjamin avatar
    12 posts
    Member since:
    Apr 2011

    Posted 13 Jan 2014 Link to this post

    Hi,

    Can we change the format in Add/Edit Scheduler?
    I have a scheduler with Custom Editor Template with start and date template using DatePicker as following.
    @(Html.Kendo().DatePickerFor(model => model.Start)
                        .Value(DateTime.Today)
                        .Format("dd MMM yyyy"))

    @(Html.Kendo().DatePickerFor(model => model.End)
                    .Value(DateTime.Today)
                    .Format("dd MMM yyyy"))

    But everytime I tried to save the New Scheduler, it always said "The field Start must be a date/ The field End must be a date".

    Is there any way to change the format?

    Thanks.
  2. Vladimir Iliev
    Admin
    Vladimir Iliev avatar
    2172 posts

    Posted 14 Jan 2014 Link to this post

    Hi Benjamin,

    From the provided information it seems that the culture on the server and the client side is different which is invalid configuration. Please check the following help topic which contains more information about how to setup the project correctly:


    Regards,
    Vladimir Iliev
    Telerik
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  3. UI for ASP.NET MVC is VS 2017 Ready
Back to Top