[Expand]General Information
[Collapse]WinForms Controls
  .NET Core Support
  Prerequisites
 [Expand]What's Installed
 [Expand]Build an Application
 [Collapse]Controls and Libraries
  [Expand]Forms and User Controls
  [Expand]Messages, Notifications, and Dialogs
  [Expand]Editors and Simple Controls
  [Expand]Ribbon, Bars and Menu
  [Expand]Application UI Manager
  [Expand]Docking Library
  [Expand]Data Grid
  [Expand]Vertical Grid
  [Expand]Property Grid
  [Expand]Pivot Grid
  [Expand]Tree List
  [Collapse]Gantt Control
    Overview
    Data Source
    Tree and Chart Areas
    Tasks, Milestones, Dependencies
    Timescale
    Workweek Schedule and Exceptions
    View Options and Appearances
    Ribbon Commands
    Localization
  [Expand]Chart Control
  [Expand]Diagrams
  [Expand]Gauges
  [Expand]Map Control
  [Expand]Scheduler
  [Expand]Spreadsheet
  [Expand]Rich Text Editor
  [Expand]Spell Checker
  [Expand]Form Layout Managers
  [Expand]Navigation Controls
  [Expand]Printing-Exporting
  [Expand]PDF Viewer
   Reporting
  [Expand]Snap
  [Expand]TreeMap Control
  [Expand]Sunburst Control
 [Expand]Common Features
  Get More Help
 [Expand]API Reference
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Expand]WPF Controls
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Office File API
[Expand]Reporting
[Expand]Report and Dashboard Server
[Expand]Dashboard
[Expand]eXpressApp Framework
[Expand]eXpress Persistent Objects
[Expand]CodeRush
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation
View this topic on docs.devexpress.com (Learn more)

Data Source

The TreeList.DataSource property allows you to specify the control's data source.

Expanded Field Names

The following properties specify data source fields that contain the data required by the control to display the project schedule (hierarchy, dates, dependencies, etc.):

Hierarchy

Tasks

Baselines

Baselines are only displayed if the GanttControlOptionsView.ShowBaselines option is enabled.

Dependencies

  • GanttChartMappings.PredecessorsFieldName — Gets or sets the data source field that specifies a task's predecessors. This field contains ID keys for predecessor tasks on which the current task depends.

How to Create Data Source in Code

The code below shows how to initialize tree list and chart mappings.

Note

Run the Gantt Code Examples demo to see the complete example.

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