I am trying to set default value of "End Time" field in Calender NewForm.aspx page. Here is my code:
var txtDate = $("#" + $("label:contains('End Time Date')").attr("for"));
var cboHours = $("#" + $("label:contains('End Time Hours')").attr("for"));
var cboMinutes = $("#" + $("label:contains('End Time Minutes')").attr("for"));
txtDate.val("1/4/2013");
cboHours.val("9 AM");
cboMinutes.val("30");
Through break point, I can see that values are properly set on respective dropdowns of "End Time" field, but after my JavaScript code, SharePoint change back those values to +1 hour of current selected "Start Time". If "Start Time" value is "1/4/2013 6:30 AM", SharePoint change back the value of "End Time" to "1/4/2013 7:30 AM".
I am wondering if there is any to set value of "End Time" through Javascript. Or else, if there is any Javascript hack to remove dependency between "Start Time" and "End time"?
