Passing the select value back to Server

2 posts, 0 answers
  1. Jay
    Jay avatar
    5 posts
    Member since:
    Feb 2008

    Posted 17 Mar 2013 Link to this post

    So is this the only way to pass the value that has been selected back to the server ...seems like way too much glue code , I have to have a hidden field, then need to use JS to fill that field etc etc


        @using (Html.BeginForm("Index", "Home", FormMethod.Post))
            @Html.HiddenFor(m => m.StartDate)
            @Html.HiddenFor(m => m.EndDate)
            <button name="button" value="save">Save Date</button>
            $(document).ready(function () {
                var calendarStart = $("#calendarStart").data("kendoCalendar");
                calendarStart.bind("change", function (e) {
                var calendarEnd = $("#calendarStart").data("kendoCalendar");
                calendarEnd.bind("change", function (e) {
  2. Petur Subev
    Petur Subev avatar
    1882 posts

    Posted 19 Mar 2013 Link to this post

    Hello Jay,

    If you want to submit the value to the server consider using the DatePicker widget other way you will have to go this way and create the hidden field which to be submitted.

    Kind Regards,
    Petur Subev
    the Telerik team
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Back to Top