[Expand]General Information
[Expand]WinForms Controls
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Collapse]WPF Controls
 [Expand]What's Installed
 [Expand].NET Core 3 Support
 [Expand]Common Concepts
 [Expand]MVVM Framework
 [Collapse]Controls and Libraries
  [Expand]Data Grid
  [Expand]Ribbon, Bars and Menu
  [Expand]Charts Suite
  [Expand]Pivot Grid
  [Expand]Rich Text Editor
  [Expand]Tree List
  [Expand]Gauge Controls
  [Expand]Map Control
  [Expand]Layout Management
  [Expand]Windows Modern UI
  [Expand]Data Editors
  [Expand]Navigation Controls
  [Expand]Spell Checker
  [Expand]Property Grid
  [Expand]PDF Viewer
  [Expand]TreeMap Control
  [Expand]Gantt Control
  [Expand]Diagram Control
  [Expand]Windows and Utility Controls
   Dialogs, Notifications and Panels
  [Collapse]Scheduler (legacy)
   [Expand]Getting Started
   [Expand]Visual Elements
    [Expand]Data Binding
    [Expand]Data Exchange
    [Expand]Date and Time
    [Collapse]Initial Settings
      How to: Set Default Values for a New Appointment (legacy)
      How to: Customize the Day View (legacy)
      How to: Customize the Work-Week View (legacy)
      How to: Customize the Week View (legacy)
      How to: Customize the Month View (legacy)
      How to: Customize the Timeline View (legacy)
      How to: Customize Time Scales in the Timeline View (legacy)
      How to: Change the Active View (legacy)
      How to: Group Appointments by Resources (legacy)
      How to: Group Appointments by Dates (legacy)
    [Expand]Range Control
 [Expand]Scaffolding Wizard
  Redistribution and Deployment
  Get More Help
 [Expand]API Reference
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Office File API
[Expand]Report and Dashboard Server
[Expand]eXpressApp Framework
[Expand]eXpress Persistent Objects
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation
View this topic on docs.devexpress.com (Learn more)

How to: Customize Time Scales in the Timeline View (legacy)


You are viewing documentation for the legacy WPF Scheduler control. If you're starting a new project, we strongly recommend that you use a new control declared in the DevExpress.Xpf.Scheduling namespace. If you decide to upgrade an existing project in order to switch to the updated scheduler control, see the Migration Guidelines document.

This example illustrates how to access the time scale collection of the Timeline View (via the TimelineView.Scales property) and add TimeScale elements to make them available to end-users (for example, TimeScaleMonth, TimeScaleWeek and TimeScaleDay). This approach can be helpful if you wish to hide specific time intervals in the Timeline View.

To change the format of a single scale header, adjust the TimeScale.DisplayFormat property of the corresponding TimeScale object.

You can also implement your own custom time scales and add them to the TimelineView.Scales collection. This example demonstrates the comparatively simple task of creating a scale with a fixed interval (four hours) by inheriting from the TimeScaleFixedInterval class. For more complex tasks, use the TimeScale descendants and override key methods.

As a result, the following time scales will be available for end-users in the Timeline View.

Is this topic helpful?​​​​​​​