[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)

Tasks, Milestones, Dependencies

The Gantt control supports the following task types:

  • Task — a regular task that has a certain duration.

  • Summary task — a task that shows combined information for its subtasks.

  • Milestone — a task with a zero duration.

The control also displays dependencies between tasks. A task can have a predecessor task that should be accomplished before the task can start.

Expanded Task Captions

A task can have captions displayed inside, to the left, and to the right of the bar. Handle the GanttControl.CustomTaskDisplayText event to provide the captions.

The code below shows how to display captions to the left and to the right of the bars.

Note

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

Expanded Context Menus

When a user right-clicks a task's bar, the control can show a context menu. To populate the menu with commands, handle the GanttControl.TaskPopupMenuShowing event.

The code below shows how to populate the context menu with items.

Expanded Tooltips

To show a tooltip for a task, handle GanttControl.TaskToolTipShowing event.

The code below shows a regular tooltip for a task.

Expanded Draw a Task Manually

You can handle the following events to draw a task manually:

The code below shows how to indicate a critical path in the project.

The code below shows how to split a task's bar into two bars.

Note

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

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