This is a migrated thread and some comments may be shown as answers.

Recurrence check box and editor

2 Answers 63 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
BET
Top achievements
Rank 1
BET asked on 05 Jun 2013, 04:36 AM
Hi,

Our rad scheduler does not show recurrence editor check box and corresponding screen elements.
 My code is given below, how can i show recurrence editor check box.



<telerik:RadScheduler ID="rsTS" runat="server" AllowInsert="False" DisplayDeleteConfirmation="False"
                            Localization-HeaderToday="Today" EnableCustomAttributeEditing="True" EnableDescriptionField="True"
                            Height="100%" EnableExactTimeRendering="true" EnableViewState="true" OverflowBehavior="Scroll"
                            CustomAttributeNames="HasAttachment,ChangedApptEndTime"    
                            ShowAllDayRow="false" OnAppointmentDataBound="TicketsSchedule_AppointmentDataBound"
                            OnNavigationComplete="rsTS_NavigationComplete" OnNavigationCommand="rsTS_NavigationCommand"
                            OnDataBound="rsTS_DataBound" 
                            OnTimeSlotCreated="rsTS_TimeSlotCreated" OnAppointmentUpdate="onApptUpdate"
                            onappointmentcancelingedit="rsTS_AppointmentCancelingEdit"  
                            OnClientAppointmentDoubleClick="rsClientAppointmentDoubleClick" OnClientAppointmentClick="singleClick"
                            OnClientAppointmentContextMenu="OnClientAppointmentContextMenu"  OnClientAppointmentContextMenuItemClicked="handleClick"
                            OnClientFormCreated="ClientFormCreated"     OnClientAppointmentEditing= "StopTimer"    
                            OnClientAppointmentMoveEnd="AppointmentMoved" OnClientAppointmentDeleting="OnClientAppointmentDeleting"
                            OnClientAppointmentMoveStart="StopTimer"  
                            onprerender="rsTS_PreRender"   >
                           <AppointmentTemplate >
                                 <div>
                                         <asp:Panel ID="RecurrencePanel" CssClass="rsAptRecurrence" runat="server" Visible="false" />
                                         <asp:Panel ID="RecurrenceExceptionPanel" CssClass="rsAptRecurrenceException" runat="server"
                                              Visible="false" />

                                        <div id="ApptImageDiv" style="text-align:right; position:absolute; width:95%;" >
                                                 <asp:Image ID="ApptAttachmentImg" runat="server"  Width="16px" Height="17px"  CssClass="ShowAttachment"
                                                 Visible='<%# String.IsNullOrEmpty(Container.Appointment.Attributes["HasAttachment"])? false : Boolean.Parse(Container.Appointment.Attributes["HasAttachment"]) %>'
                                                  />
                                            
                                                 <asp:Image ID="ChangedApptEndTime" runat="server"  Width="19px" Height="17px"  CssClass="ShowApptEndTimeChanged"    
                                                          Visible='<%# String.IsNullOrEmpty(Container.Appointment.Attributes["ChangedApptEndTime"])? false : Boolean.Parse(Container.Appointment.Attributes["ChangedApptEndTime"]) %>'
                                                  />
                                              
                                          </div>
                                         <%#Eval("Subject") %>     
                                  
                                  </div>
                            </AppointmentTemplate    >
                        
                            <AppointmentContextMenus     >
                            </AppointmentContextMenus>
                            <DayView UserSelectable="True" GroupBy="TechName" GroupingDirection="Horizontal" />
                            <WeekView UserSelectable="True" GroupBy="TechName" GroupingDirection="Vertical" />
                            <MonthView UserSelectable="True" GroupBy="TechName" GroupingDirection="Vertical" />
                            <TimelineView ColumnHeaderDateFormat="h:mm tt" GroupingDirection="Vertical" HeaderDateFormat="MM/dd/yyyy h:mm tt"
                                NumberOfSlots="21" SlotDuration="00:30:00" StartTime="08:00:00" />
                            <AdvancedForm EnableCustomAttributeEditing="True" Modal="True" />
                            <ResourceTypes>
                                <telerik:ResourceType Name="TechName" />
                                <telerik:ResourceType Name="TicketState" />
                            </ResourceTypes>
                        </telerik:RadScheduler>

Thanks for your help in advance.

2 Answers, 1 is accepted

Sort by
0
BET
Top achievements
Rank 1
answered on 08 Jun 2013, 01:45 PM

Now, I am able to see recurrence.

But there is one small issue, now I am unable to close, save and cancel in the edit appointment window.

Any help would be appreciated.

Thanks in advance.

 I added highlighted code 

function ClientFormCreated(sender, e) {

                 

                  StopTimer();                 

                  var startDatejQueryObject = $("[id$='Form_StartDate']");

                  var startDatePicker = $find(startDatejQueryObject.attr("id"));

                  var startTimejQueryObject = $("[id$='Form_StartTime']");

                  var startTimePicker = $find(startTimejQueryObject.attr("id"));

                  startDatePicker.add_dateSelected(ChangeEndDate);

                  startTimePicker.add_dateSelected(ChangeEndTime);

                  // Create a client-side object only for the advanced templates

                  var mode = e..get_mode();

                  if (mode == Telerik.Web.UI.SchedulerFormMode.AdvancedInsert ||

                         mode == Telerik.Web.UI.SchedulerFormMode.AdvancedEdit) {

                      // Initialize the client-side object for the advanced form

                      var formElement = e.get_formElement();

                      var templateKey = scheduler.get_id() + "_" + mode;

                      var advancedTemplate = schedulerTemplates[templateKey];

                      if (!advancedTemplate) {

                          // Initialize the template for this RadScheduler instance

                          // and cache it in the schedulerTemplates dictionary

                          var schedulerElement = scheduler.get_element();

                          var isModal = scheduler.get_advancedFormSettings().modal;

                          advancedTemplate = new window.SchedulerAdvancedTemplate(schedulerElement, formElement, isModal);

                          advancedTemplate.initialize();

                          schedulerTemplates[templateKey] = advancedTemplate;

                          // Remove the template object from the dictionary on dispose.

                          scheduler.add_disposing(function () {

                              schedulerTemplates[templateKey] = null;

                          });

                      }

                  }

                 

              }

<telerik:RadScheduler ID="rsTicketsSchedule" runat="server" AllowInsert="False" DisplayDeleteConfirmation="False"

                            Localization-HeaderToday="Today" EnableCustomAttributeEditing="True" EnableDescriptionField="True"

                            Height="100%" EnableExactTimeRendering="true" EnableViewState="true" OverflowBehavior="Scroll"

                            CustomAttributeNames="HasAttachment" DataReminderField = "Reminder"

                            ShowAllDayRow="false" OnAppointmentDataBound="TicketsSchedule_AppointmentDataBound"

                            OnNavigationComplete="rsTicketsSchedule_NavigationComplete" OnNavigationCommand="rsTicketsSchedule_NavigationCommand"

                            OnDataBound="rsTicketsSchedule_DataBound"

                            OnTimeSlotCreated="rsTicketsSchedule_TimeSlotCreated" OnAppointmentUpdate="onApptUpdate"

                            onappointmentcancelingedit="rsTicketsSchedule_AppointmentCancelingEdit" 

                            OnClientAppointmentDoubleClick="rsClientAppointmentDoubleClick" OnClientAppointmentClick="singleClick"

                            OnClientAppointmentContextMenu="OnClientAppointmentContextMenu"  OnClientAppointmentContextMenuItemClicked="handleClick"

                            OnClientFormCreated="ClientFormCreated"     OnClientAppointmentEditing= "StopTimer"   

                            OnClientAppointmentMoveEnd="AppointmentMoved" OnClientAppointmentDeleting="OnClientAppointmentDeleting"

                            OnClientAppointmentMoveStart="StopTimer" 

                            onprerender="rsTicketsSchedule_PreRender"

                           

                            DataRecurrenceField="RecurrenceRule"    DataRecurrenceParentKeyField="RecurrenceParentID"  >

                        

                         <AdvancedForm EnableCustomAttributeEditing="True" Modal="True" />

                           <AppointmentTemplate >

                                 <div>

                                         <asp:Panel ID="RecurrencePanel" CssClass="rsAptRecurrence" runat="server" Visible="true" />

                                         <asp:Panel ID="RecurrenceExceptionPanel" CssClass="rsAptRecurrenceException" runat="server"

                                              Visible="false" />

                                              <%--  <asp:Panel ID="ReminderPanel" CssClass="rsAptReminder" runat="server" Visible="true" />--%>

                                        <div id="ApptImageDiv" style="text-align:right; position:absolute; width:95%;" >

                                                 <asp:Image ID="ApptAttachmentImg" runat="server"  Width="16px" Height="17px"  CssClass="ShowAttachment"

                                                 Visible='<%# String.IsNullOrEmpty(Container.Appointment.Attributes["HasAttachment"])? false : Boolean.Parse(Container.Appointment.Attributes["HasAttachment"]) %>'

                                                  />

                                           

                                                

                                             

                                          </div>

                                         <%#Eval("Subject") %>    

                                 

                                  </div>

                            </AppointmentTemplate    >

                       

                    <%--     <AdvancedEditTemplate>

                                 <scheduler:AdvancedForm runat="server" ID="AdvancedEditForm1" Mode="Edit"  >

                                        </scheduler:AdvancedForm>

                                    

                         </AdvancedEditTemplate>--%>

                            <AppointmentContextMenus >

                            </AppointmentContextMenus>

                            <DayView UserSelectable="True" GroupBy="TechName" GroupingDirection="Horizontal" />

                            <WeekView UserSelectable="True" GroupBy="TechName" GroupingDirection="Vertical" />

                            <MonthView UserSelectable="True" GroupBy="TechName" GroupingDirection="Vertical" />

                            <TimelineView ColumnHeaderDateFormat="h:mm tt" GroupingDirection="Vertical" HeaderDateFormat="MM/dd/yyyy h:mm tt"

                                NumberOfSlots="21" SlotDuration="00:30:00" StartTime="08:00:00" />

                          

                            <ResourceTypes>

                                <telerik:ResourceType Name="TechName" />

                                <telerik:ResourceType Name="TicketState" />

                            </ResourceTypes>

                            <Reminders Enabled="true"></Reminders>

                        </telerik:RadScheduler>

0
Kate
Telerik team
answered on 24 Jun 2013, 02:56 PM
Hi BET,

I tried running the code that you provided but to no avail. Can you please open an official support ticket where you can attach a very simplified runnable project that I will be able to run and test locally so I can help you out in the most efficient way? I would also like to ask you to clarify the exact issue that you re currently experiencing.

Regards,
Kate
Telerik
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
Tags
Scheduler
Asked by
BET
Top achievements
Rank 1
Answers by
BET
Top achievements
Rank 1
Kate
Telerik team
Share this question
or