Scheduler HeaderTitle

2 posts, 1 answers
  1. Andy
    Andy avatar
    9 posts
    Member since:
    Aug 2010

    Posted 12 Aug 2010 Link to this post

    Is there a way to hard code a header title to the Scheduler?

    So, rather than a pair of dates in the format "dd dddd" or "dd/mm", for example, having a title of "Calendar"?
    If not, can you hide the top header, but still display the individual headers for each day?
    The ShowHeader flag hides both sets of headers when I set it to False

    Thanks
  2. Answer
    Dobry Zranchev
    Admin
    Dobry Zranchev avatar
    348 posts

    Posted 16 Aug 2010 Link to this post

    Hi Andy,

    Thank you for contacting us.

    You could subscribe for the LayoutUpdated event of the upper header element in timeline view. In this event you could set the custom text to this element. Here is a sample snippet:
    Copy Code
    SchedulerTimelineViewElement element = this.radScheduler1.SchedulerElement.ViewElement as SchedulerTimelineViewElement;
    element.Header.Children[0].LayoutUpdated += new EventHandler(LayoutUpdated);
     
    void LayoutUpdated(object sender, EventArgs e)
    {
        SchedulerTimelineViewElement element = this.radScheduler1.SchedulerElement.ViewElement as SchedulerTimelineViewElement;
        SchedulerHeaderCellElement headerElement = element.Header.Children[0] as SchedulerHeaderCellElement;
        headerElement.Text = "custom text";
    }
    I hope that this will help you.

    If you have other questions, feel free to contact us.

    Regards,
    Dobry Zranchev
    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
  3. UI for WinForms is Visual Studio 2017 Ready
Back to Top