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

[Solved] Tooltip+Schedular is not working for any other months.

2 Answers 77 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Prashant Dalvi
Top achievements
Rank 1
Prashant Dalvi asked on 01 Mar 2010, 03:21 PM
Hi All,

We have implemented code in our application from http://demos.telerik.com/aspnet-ajax/scheduler/examples/radtooltip/defaultcs.aspx.
And its working properly for single same month but when we navigate to any other months then its not working.

aspx Code is:
 <ContentTemplate>
        <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server"  />
                    <telerik:RadScheduler runat="server" ID="RadScheduler1"  Height="600px" StartEditingInAdvancedForm="false"
                        ShowFooter="false" TimeZoneOffset="05:30:00" DayStartTime="00:00:01" SelectedView="MonthView" ShowViewTabs="false"
                        DayEndTime="23:59:59" FirstDayOfWeek="Monday" LastDayOfWeek="Sunday" EnableDescriptionField="true" AllowEdit="false" AllowInsert="false"
                        OnDataBound="RadScheduler1_DataBound" DataKeyField="EventID" DataSubjectField="EventName" DataStartField="EventDate" DataEndField="EventDate"
                        Width="100%" OnNavigationComplete="RadScheduler1_NavigationComplete" OnAppointmentDataBound="RadScheduler1_AppointmentDataBound"
                        AllowDelete="false"  onappointmentcreated="RadScheduler1_AppointmentCreated">
                        <%--<AdvancedForm  modal="true" />--%>
                        <TimelineView UserSelectable="false" />
                        <ResourceStyles>
                            <telerik:ResourceStyleMapping Type="Calendar" Text="Development" ApplyCssClass="rsCategoryGreen" />
                            <telerik:ResourceStyleMapping Type="Calendar" Text="Marketing" ApplyCssClass="rsCategoryRed" />
                            <telerik:ResourceStyleMapping Type="Calendar" Text="Work" ApplyCssClass="rsCategoryOrange" />
                        </ResourceStyles>
                    </telerik:RadScheduler>
                    <telerik:RadToolTipManager runat="server" ID="RadToolTipManager1" Width="300" Height="100"
                Animation="None" HideEvent="LeaveToolTip" Text="Loading..." RelativeTo="Element"
                OnAjaxUpdate="RadToolTipManager1_AjaxUpdate" OnClientBeforeShow="clientBeforeShow"  BackColor="#390f12"
                /></ContentTemplate>

and cs code is:
 protected void RadToolTipManager1_AjaxUpdate(object sender, Telerik.Web.UI.ToolTipUpdateEventArgs args)
        {  
            
            this.UpdateToolTip(args.Value, args.UpdatePanel);
        }

        private void UpdateToolTip(string elementID, UpdatePanel panel)
        {
            int aptId;
            Appointment apt;

            try
            {
                if (!int.TryParse(elementID, out aptId))//The appoitnment is occurrence and FindByID expects a string
                    apt = RadScheduler1.Appointments.FindByID(elementID);
                else //The appointment is not occurrence and FindByID expects an int
                    apt = RadScheduler1.Appointments.FindByID(aptId);

                EventDetails toolTip = (EventDetails)LoadControl("EventDetails.ascx");
                toolTip.TargetAppointment = apt;
                panel.ContentTemplateContainer.Controls.Add(toolTip);
            }
            catch (Exception ex)
            {
                objbbCommon.WriteError(ex.Message.ToString());
            }
        }

Thanks in advance for your support.



2 Answers, 1 is accepted

Sort by
0
Peter
Telerik team
answered on 02 Mar 2010, 06:54 AM
Hi Prashant,

Please make sure that in your RadAjaxManager settings, RadScheduler updates RadTooltTipManager. This is the most common reason for the problem that you describe. Or, you can simply disable or remove RadAjaxManager and test the case to check if this is the culprit.


Kind regards,
Peter
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
0
Prashant Dalvi
Top achievements
Rank 1
answered on 02 Mar 2010, 07:52 AM
Hi Peter,

Thanks for your solution. I have removed RadAjaxManager from ".aspx"  code and its working properly.

Thanks,

Prashant Dalvi
Tags
Scheduler
Asked by
Prashant Dalvi
Top achievements
Rank 1
Answers by
Peter
Telerik team
Prashant Dalvi
Top achievements
Rank 1
Share this question
or