Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C# ASP.NET Javascript
I have the following javascript which works fine in Mozilla but not working in Chrome or IE
function TimeCheck() {        
    
         var Date1 = new Date(StartTime.get_selectedDate())       
         var date2 = new Date(Date1);
         var date3=date2.setMinutes(date2.getMinutes() + 30);
         var Endtime = new Date(date3);
           document.getElementById('ctl02_ViewEventsOnCalendar1_SchedulerControl_Form_EditEventControl_EndTime_dateInput_display').innerHTML = Endtime.format("M/d/yyyy h:mm tt");
document.getElementById('hfEndTime').value = Endtime.format("M/d/yyyy h:mm tt");
      
     }
 
And using the following code in aspx on Telerik RadeDateTimePicker onchange event
<telerik:RadDateTimePicker ID="StartTime"  runat="server" Skin="Office2007" TimeView-EndTime="22:00:00" 
                    TimeView-Interval="00:30:00" TimeView-StartTime="07:00:00" AutoPostBackControl="None"  onchange="javascript:TimeCheck();"
                    
                     önSelectedDateChanged="StartTime_SelectedDateChanged">
                    <TimePopupButton ImageUrl="" HoverImageUrl="" ></TimePopupButton>
                    <TimeView CellSpacing="-1" Culture="English (United Kingdom)"  önClientTimeSelected="OnClientTimeSelected"  >
                    </TimeView>
                    <DateInput AutoPostBack="false" >
                        <ClientEvents OnLoad="onLoadRadTimePicker1"  önValueChanged="validateBackdate" />
                    </DateInput>
                    <Calendar UseRowHeadersAsSelectors="False" UseColumnHeadersAsSelectors="False" ViewSelectorText="x" 
                        Skin="Office2007">
                    </Calendar>
                    <DatePopupButton ImageUrl="" HoverImageUrl="" ></DatePopupButton>
                </telerik:RadDateTimePicker>
Posted 15-Jan-13 22:56pm
Comments
Abhishek Pant at 16-Jan-13 4:19am
   
I think that javascipt is not enabled in your browser- IE or chrome
check it-How to enable JavaScript in your browser[^]
Tirthankar Dutta at 16-Jan-13 4:45am
   
No..its enabled..
Soroush Falahati at 20-Jan-13 15:23pm
   
Check for Javascript errors and let us know it. Then we can help:
https://chrome.google.com/webstore/detail/javascript-errors-notifie/jafmfknfnkoekkdocjiaipcnmkklaajd
http://msdn.microsoft.com/en-us/library/ie/gg699336%28v=vs.85%29.aspx

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Sergey Alexandrovich Kryukov 450
1 OriginalGriff 230
2 DamithSL 150
3 Dave Kreskowiak 110
4 Suvendu Shekhar Giri 110
0 OriginalGriff 7,740
1 DamithSL 5,644
2 Sergey Alexandrovich Kryukov 5,404
3 Maciej Los 5,011
4 Kornfeld Eliyahu Peter 4,539


Advertise | Privacy | Mobile
Web01 | 2.8.141223.1 | Last Updated 16 Jan 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100