Hi ,
I've built a SharePoint webpart that uses a radScheduler in Timeline view. The oddest thing Ive seen happens with the scheduler. In IE 8 it renders great and works like a charm. However in IE 7, when a user clicks the next and previous buttons and then mouses out , the scheduler simply disappears. The next and previous buttons do not make any server calls as I've bound 10 days worth of appointment data when the form initiallys loads. Any help with this would be appreciated.
Here is the aspx code for the control:
Here is the code that initialises the control through code:
And here are the server side events I've hooked into:
I've built a SharePoint webpart that uses a radScheduler in Timeline view. The oddest thing Ive seen happens with the scheduler. In IE 8 it renders great and works like a charm. However in IE 7, when a user clicks the next and previous buttons and then mouses out , the scheduler simply disappears. The next and previous buttons do not make any server calls as I've bound 10 days worth of appointment data when the form initiallys loads. Any help with this would be appreciated.
Here is the aspx code for the control:
<br /> <style type="text/css"> .rsTimelineView .rsAllDayRow { height:32px !important; } .rsContentScrollArea { /*overflow-x: scroll;*/ } .rhs table tbody tr td iframe { z-index: 9000000!important; } .rsAllDayTable ,.rsHorizontalHeaderTable { width:100%!Important; } .RadScheduler, .rsHeader { /*Z-index:0!important;*/ } .rsHeader { /*z-index:1; */ /*z-index:0!Important; */ } .rsContent { position:relative; /*top:-8px;*/ top:0px; /*z-index:-1!important;*/ } .rsAptRecurrenceException { display:none!important; } .ms-inputuserfield { border-style:solid; border-color:Gray; border-width:1px; } /*.rsAptOut*/ .overrideRsAptOut { width: inherit !important; } .placeholder { /*border-color:Teal; border-width:1px; border-style:solid;*/ } .clear { float:none; clear: both; } .lhs { position:relative; float:left; width: 150px; } .rhs { position:relative; float:left; width:300px; margin-right:10px; margin-left:5px; } #divResourcePicker { padding-top:10px!important; } #divDisplayMissingResources, .errors { padding-top:10px; color:Red; } #divDisplayAvailability { margin:0px auto 0px auto; padding-top:10px; } #divGetAvailability, #divDisplayMissingResources, #divDisplayAvailability { position:relative; top:40px; } </style> <script type="text/javascript" src="~/_layouts/Amp.AvailabilityViewer.SharePoint/jquery-1.6.2.min.js"></script> <script type="text/javascript"> </script> <div id="divWebPartContainer" > <div id= "divStartDateTime"> <div class="lhs placeholder"> Start Date & Time </div> <div class="rhs placeholder"> <SharePoint:DateTimeControl ID="dtcStartingDateTime" runat="server" /> </div> </div> <div class="clear"></div> <div id= "divResourcePicker"> <div class="lhs placeholder"> Names</div> <div class="rhs placeholder" style="height:26px;"> <SharePoint:PeopleEditor id="peopleEditor" runat="server" IsValid="true" AllowEmpty="true" Height="20px" Width="290px" AllowTypeIn="true" MultiSelect="true" /> </div> </div> <div class="clear"></div> <div id= "divGetAvailability"> <div class="lhs placeholder"> <asp:Button ID="btnCheckAvailability" runat="server" Text="Check Availability" onclick="btnCheckAvailability_Click" /> </div> <div class="rhs placeholder"> </div> </div> <div class="clear"></div> <asp:Panel ID="pnlDisplayMissingResources" runat="server" visible="false"> <div id= "divDisplayMissingResources"> <div class="lhs placeholder"></div> <div class="rhs placeholder"> <asp:Literal ID="litInaccableCalendars" runat="server" ></asp:Literal></div> </div> </asp:Panel> <div class="clear"></div> <div id= "divDisplayAvailability" class="placeholder"> <asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode="Conditional"> <ContentTemplate> <div class="lhs placeholder"></div> <div class="rhs placeholder"><asp:Label ID="RadSchedulerError" runat="server" Text="" Visible="false" CssClass="errors"></asp:Label></div> <div class="clear"></div> <telerik:RadScheduler ID="RadScheduler1" runat="server" AllowEdit="false" AllowInsert="false" ShowViewTabs="false" OnAppointmentCreated="RadScheduler1_AppointmentCreated" ShowNavigationPane="true" EnableExactTimeRendering="true" OnNavigationCommand = "RadScheduler1_NavigationCommand" EnableDatePicker="false" visible="true" > <AdvancedForm Modal="true" /> <TimelineView GroupingDirection="Vertical" /> <MonthView UserSelectable="false" /> <DayView UserSelectable="false" /> <WeekView UserSelectable="false" /> </telerik:RadScheduler> </ContentTemplate> </asp:UpdatePanel> </div> <br /> </divHere is the code that initialises the control through code:
private void initialiseSchedulerUI() { RadScheduler1.SelectedView = Telerik.Web.UI.SchedulerViewType.TimelineView; RadScheduler1.DayStartTime= TimeSpan.Parse("08:00:00") ; RadScheduler1.DayEndTime=TimeSpan.Parse("19:00:00") ; RadScheduler1.Skin= "Office2007" ; RadScheduler1.TimelineView.UserSelectable = false; RadScheduler1.TimelineView.GroupBy = "User"; RadScheduler1.TimelineView.ShowInsertArea = false; //Timescales scale = Timescales.Hours; //RadScheduler1.TimelineView.ShowTimescale(scale); RadScheduler1.DataKeyField = "ID"; RadScheduler1.DataStartField = "Start"; RadScheduler1.DataDescriptionField = "Subject"; RadScheduler1.DataEndField = "End"; RadScheduler1.DataSubjectField = "Subject"; RadScheduler1.DataRecurrenceField = "RecurrenceRule"; RadScheduler1.DataRecurrenceParentKeyField = "RecurrenceParentID"; //RadScheduler1.OverflowBehavior="Expand" ; RadScheduler1.TimelineView.SlotDuration = TimeSpan.Parse("00:15:00"); RadScheduler1.TimelineView.TimeLabelSpan = 4; RadScheduler1.TimelineView.ColumnHeaderDateFormat = "h tt"; RadScheduler1.TimelineView.NumberOfSlots = 64; RadScheduler1.TimelineView.StartTime = TimeSpan.Parse("08:00:00"); RadScheduler1.TimelineView.HeaderDateFormat = "dddd, dd MMMM yyyy"; RadScheduler1.RowHeight = Unit.Pixel(32); RadScheduler1.ReadOnly = true; }And here are the server side events I've hooked into:
protected void RadScheduler1_NavigationCommand(object sender, SchedulerNavigationCommandEventArgs e) { string radDate; // = startDate.ToShortDateString(); string dtcDate; DateTime convertedRadDate; //= DateTime.Parse(sDate); DateTime converteddtcDate; radDate = RadScheduler1.SelectedDate.ToShortDateString(); dtcDate = dtcStartingDateTime.SelectedDate.ToShortDateString(); convertedRadDate = DateTime.Parse(radDate); converteddtcDate = DateTime.Parse(dtcDate); if (RadScheduler1.SelectedView == SchedulerViewType.TimelineView) { if (e.Command == SchedulerNavigationCommand.NavigateToNextPeriod) { RadScheduler1.SelectedDate = RadScheduler1.SelectedDate.AddHours(8); RemoveRadEditorError(); //if (RadScheduler1.SelectedDate > dtcStartingDateTime.SelectedDate.AddDays(5)) if (convertedRadDate > converteddtcDate.AddDays(5)) { DisplayRadEditorError("You can only browse five days in Advance!"); RadScheduler1.SelectedDate = RadScheduler1.SelectedDate.AddHours(-8); e.Cancel = true; UpdatePanel1.Update(); } } else if (e.Command == SchedulerNavigationCommand.NavigateToPreviousPeriod) { RadScheduler1.SelectedDate = RadScheduler1.SelectedDate.AddHours(-8); RemoveRadEditorError(); //if (RadScheduler1.SelectedDate < dtcStartingDateTime.SelectedDate) if (convertedRadDate <= converteddtcDate) { DisplayRadEditorError("You cannot browse before the selected date!"); RadScheduler1.SelectedDate = RadScheduler1.SelectedDate.AddHours(8); e.Cancel = true; UpdatePanel1.Update(); } } } } protected void RemoveRadEditorError() { RadSchedulerError.Text = ""; //RadScheduler1.Visible = true; RadSchedulerError.Visible = false; }