disable scrollbar in mothly view scheduler

Posted by: kisar on 18 September 2017, 10:14 am EST

  • Posted 18 September 2017, 10:14 am EST

    Hi, is it possible to disable the scrollbar in the scheduler component when it's in montly view? It would be useful for doesnt show some period still not loaded.
    Thank you
  • Marked as Answer

    Replied 19 September 2017, 1:26 am EST

    Hi,
    Yes, you can disable scrollbar in scheduler control using the below steps:
    1) Create a custom scheduler inherited from C1Scheduler.
    class CustomScheduler : C1Scheduler
    {
    public override void OnApplyTemplate()
    {
    base.OnApplyTemplate();
    ScrollBar scroll = GetTemplateChild("PART_C1SchedulerScrollBar") as ScrollBar;
    if (this.ViewType==ViewType.Month)
    {
    // scroll.Visibility = System.Windows.Visibility.Collapsed;
    scroll.IsEnabled = false;
    }
    }
    }


    2) Use the same in you project
    <local:CustomScheduler x:Name="scheduler" Grid.Row="1" HorizontalAlignment="Stretch"  VerticalAlignment="Stretch" ViewType="Month" />


    Also find the sample attached for complete implementation.

    scrollbarVisibilityFalse.zip

    Thanks,
    Singh Sonu
  • Replied 19 September 2017, 9:06 am EST

    perfect, thanx
Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels