Current filter:
                                You should refresh the page.
                                  • With a previous version of your controls I created a custom appointment tooltip with a popup container control following your directions in the ticket with id T290954.

                                    After I upgraded DevExpress to version 18.x the tooltip is not working.
                                    How can I achieve the same functionality with 18.x version of DevExpress control?

                                1 Solution

                                Creation Date Importance Sort by

                                Hi,

                                By default, SchedulerControl shows an appointment flyout instead of a regular tooltip. To display tooltips instead of flyouts, set the SchedulerOptionsCustomization.AllowDisplayAppointmentFlyout option to false and specify the SchedulerOptionsView.ToolTipVisibility property as required.

                                However, I should note that flyouts are inspired by a modern version of Outlook, and you can show any control within them by handling the SchedulerControl.AppointmentFlyoutShowing event. That is why, I suggest switching to flyouts.

                                UPDATED:

                                We have changed DayView's cells calculators in version 15.2. In the previous versions, an empty space that remained after dividing the DayView's client area into rows was shared between all time cells. Now, this space is moved to AllDayArea. The SchedulerControl elements are calculated in absolute coordinates. Use the AppointmentViewInfo.ConvertToVisualBounds method to convert the current rectangle to client coordinates:

                                [C#]
                                Rectangle rect = appointmentViewInfo.Items[0].Bounds; rect = appointmentViewInfo.ConvertToVisualBounds(rect);
                                Show all comments
                                • chatzikk 11.05.2019

                                  Thank you very much for your answer.
                                  I tried to switch to flyouts as you suggested but I have two issues:

                                  1. On the tooltip I have some buttons with actions. How can I use this feature with flyout? The flyout disappears as soon as I move the mouse from the appointment.
                                  2. I want the flyout to be visible only when the mouse cursor stays for a while over the image on the top left corner of the appointment.

                                  Is it possible to achieve the above functionality with the flyouts?

                                • Svetlana (DevExpress Support) 11.06.2019

                                  Hi,

                                  Currently, a flyout is always hidden on moving the cursor outside of a tooltip and there is no way to change this behavior.

                                  However, since version 19.2 is available to you, I would recommend trying our new Flyout Hints. Unlike scheduler's flyouts, they are supported directly by ToolTipController and allow you to show any interactive content within them. That is, you will be able to click your buttons without closing a flyout. In this case, it will be necessary to turn off the SchedulerOptionsCustomization.AllowDisplayAppointmentFlyout option.

                                  Please refer to the How to use a custom UserControl as a tooltip example to see how this feature operates.

                                • chatzikk 11.07.2019

                                  Thank you very much.
                                  It looks ok now but I need one more thing. I want the flyout to be visible only when the mouse is over the image on the top left corner of the appointment. When the mouse is over the body of the appointment I do not want the flyout to be displayed.

                                • Svetlana (DevExpress Support) 11.08.2019

                                  Hi,

                                  If you started using new Flyout Hints in version 19.2, all you need is to handle the ToolTipController.GetActiveObjectInfo event:

                                  [C#]
                                  private void Controller_GetActiveObjectInfo(object sender, ToolTipControllerGetActiveObjectInfoEventArgs e) { if(e.Info != null && Equals(e.SelectedControl, schedulerControl)) { SchedulerHitInfo hitInfo = schedulerControl.ActiveView.ViewInfo.CalcHitInfo(e.ControlMousePosition, false); AppointmentViewInfo appointmentViewInfo = hitInfo.ViewInfo as AppointmentViewInfo; if(appointmentViewInfo != null) { if(appointmentViewInfo.Items[0].Bounds.Contains(e.ControlMousePosition)) { e.Info.ToolTipType = ToolTipType.Flyout; e.Info.FlyoutControl = //your control here } else e.Info = null; } } }

                                  The key point here is to check where the cursor is currently shown and set the e.Info property to null to prevent showing a tooltip when needed.

                                • chatzikk 11.09.2019

                                  I tried the solution you suggested and I have the following behavior:
                                  When the Scheduler is initially loaded it works fine
                                  appointmentViewInfo.Items[0].Bounds --> (1179,600)
                                  e.ControlMousePosition --> (1180,607)

                                  When the scheduler scrolls down the appointmentViewInfo.Items[0].Bounds remains the same (1179,600) but for e.ControlMousePosition the Y value is changing eg (1180,429) and after scrolling again (1180,300).
                                  As a result the flyout is not showing after scrolling the scheduler.
                                  It starts working again as soon as the scheduler returns to it's initial position.

                                • Svetlana (DevExpress Support) 11.11.2019

                                  Hi,

                                  I could not reproduce this issue. Coordinates of an appointment above which the cursor is located are correct on my side. I have recorded a video to show my results and attached my test sample for your reference as well. Feel free to modify my project to illustrate how to see the issue.

                                • chatzikk 11.12.2019

                                  The appointmentViewInfo.Items[0].Bounds.Location is always the same as expected.
                                  The problem comes from the coordinates of the e.ControlMousePosition which changes when the scheduler scrolls.
                                  This is the reason why the expression appointmentViewInfo.Items[0].Bounds.Contains(e.ControlMousePosition) is true initially
                                  but when the scheduler is scrolled the expression returns false .

                                  As I have implemented this tooltip 5 years ago the expression was working as expected  with version 14 of the controls. It stopped working after the upgrade to version 17 and above.

                                • Svetlana (DevExpress Support) 11.13.2019

                                  Hi,

                                  I understand your point. However, if you review the test sample and video I sent to you previously, you will notice that tooltips are properly shown even if I scroll SchedulerControl. That is why I need your assistance in reproducing the issue you faced. Please modify my sample according to your scenario or describe the necessary reproduction steps if I misinterpreted them.

                                • chatzikk 11.13.2019

                                  Hi,
                                  in the sample you sent me the scheduler does not scroll up and down.The problem comes when the scheduler scrolls up or down. I use day view groupped by Resources. Please take a look at the attached video.

                                • Svetlana (DevExpress Support) 11.14.2019

                                  Hi,

                                  I also scrolled SchedulerControl up and down after changing the number of visible resources at runtime. I illustrated my actual steps by using a video and attached it to my comment together with my test sample on Nov 11, 2019. Please refer to this comment if you overlooked my video.

                                  However, my project uses TimeliveView while yours is DayView. By using DayView, I was able to reproduce the behavior. Now, you need to take the SchedulerControl.ActiveView.ViewInfo.ScrollOffset property value into account:

                                  [C#]
                                  Rectangle rect = appointmentViewInfo.Items[0].Bounds; rect.Y -= schedulerControl.ActiveView.ViewInfo.ScrollOffset;
                                • Svetlana (DevExpress Support) 11.14.2019

                                  Just a follow-up:

                                  We have changed DayView's cells calculators in version 15.2. In the previous versions, an empty space that remained after dividing the DayView's client area into rows was shared between all time cells. Now, this space is moved to AllDayArea. The SchedulerControl elements are calculated in absolute coordinates. Use the AppointmentViewInfo.ConvertToVisualBounds method to convert the current rectangle to client coordinates:

                                  [C#]
                                  Rectangle rect = appointmentViewInfo.Items[0].Bounds; rect = appointmentViewInfo.ConvertToVisualBounds(rect);

                                  This approach is similar to the one described in my previous comment.

                                • chatzikk 11.14.2019

                                  I tried the first solution and works. The condition now has to be

                                  Rectangle rect = appointmentViewInfo.Items[0].Bounds;
                                  rect.Y -= tree.ActiveView.ViewInfo.ScrollOffset;
                                  if (rect.Contains(e.ControlMousePosition))
                                      ShowFlyout();
                                  else
                                       e.Info = null;

                                  I will try the second one as well.
                                  In any case thank you very much for your help.