This sample illustrates how to apply and visualize task constraints in a Gantt Chart. Task constraints define specific scheduling rules that determine when a task can start or finish, based on project requirements or dependencies.
ID | Job Name | Start Date | Duration | Constraint Type | Constraint Date | End Date | Dependency | Progress |
---|---|---|---|---|---|---|---|---|
1 | Planning and Permits | 4/2/2025 | 8 days | As Soon As Possible | 4/11/2025 | 100 | ||
2 | Site Evaluation | 4/2/2025 | 2 days | Start No Earlier Than | 4/2/2025 | 4/3/2025 | 100 | |
3 | Obtain Permits | 4/7/2025 | 3 days | Must Start On | 4/7/2025 | 4/9/2025 | 2FS+2 days | 100 |
4 | Finalize Planning | 4/10/2025 | 2 days | Finish No Earlier Than | 4/11/2025 | 4/11/2025 | 3FS | 100 |
5 | Site Preparation | 4/14/2025 | 15 days | As Soon As Possible | 5/2/2025 | 100 | ||
6 | Site Clearing | 4/14/2025 | 0 days | As Late As Possible | 4/14/2025 | 100 | ||
7 | Grading and Excavation | 4/14/2025 | 3 days | As Soon As Possible | 4/16/2025 | 6FS | 100 | |
8 | Foundation Work | 4/18/2025 | 4 days | Start No Earlier Than | 4/18/2025 | 4/23/2025 | 7FS+1 day | 100 |
9 | Foundation and Basement | 4/24/2025 | 7 days | As Soon As Possible | 5/2/2025 | 100 | ||
10 | Pour Foundation | 4/24/2025 | 2 days | Start No Earlier Than | 4/24/2025 | 4/25/2025 | 8FS | 100 |
11 | Cure Foundation | 4/28/2025 | 2 days | Must Finish On | 4/29/2025 | 4/29/2025 | 10FS | 100 |
12 | Basement Walls | 4/30/2025 | 3 days | As Soon As Possible | 5/2/2025 | 11FS | 100 | |
13 | Framing | 5/1/2025 | 10 days | As Soon As Possible | 5/14/2025 | 100 | ||
14 | Frame Floors | 5/1/2025 | 2 days | Start No Earlier Than | 5/1/2025 | 5/2/2025 | 100 | |
15 | Frame Walls | 5/8/2025 | 2 days | Must Start On | 5/8/2025 | 5/9/2025 | 14FS+3 days | 100 |
16 | Install Trusses | 5/13/2025 | 2 days | Finish No Earlier Than | 5/14/2025 | 5/14/2025 | 15FS | 100 |
17 | Roofing | 5/15/2025 | 3 days | As Late As Possible | 5/19/2025 | 16FS | 100 | |
18 | Mechanical, Electrical, Plumbing | 5/14/2025 | 9 days | As Soon As Possible | 5/26/2025 | 50 | ||
19 | HVAC Installation | 5/14/2025 | 3 days | Start No Earlier Than | 5/14/2025 | 5/16/2025 | 100 | |
20 | Plumbing Installation | 5/19/2025 | 3 days | Finish No Earlier Than | 5/21/2025 | 5/21/2025 | 19FS | 50 |
21 | Electrical Installation | 5/22/2025 | 3 days | Finish No Later Than | 5/26/2025 | 5/26/2025 | 20FS | 0 |
22 | Interior Finishing | 5/27/2025 | 19 days | As Soon As Possible | 6/20/2025 | 0 | ||
23 | Insulation and Drywall | 5/27/2025 | 5 days | Start No Earlier Than | 5/27/2025 | 6/2/2025 | 21FS | 0 |
24 | Interior Painting | 6/3/2025 | 4 days | Finish No Earlier Than | 6/6/2025 | 6/6/2025 | 23FS | 0 |
25 | Flooring Installation | 6/9/2025 | 4 days | Start No Later Than | 6/12/2025 | 6/12/2025 | 24FS | 0 |
26 | Cabinet and Fixture Setup | 6/13/2025 | 3 days | As Late As Possible | 6/17/2025 | 25FS | 0 | |
27 | Final Fixture Installation | 6/18/2025 | 3 days | As Soon As Possible | 6/20/2025 | 26FS | 0 | |
28 | Exterior Finishing | 6/23/2025 | 4 days | Must Start On | 6/23/2025 | 6/26/2025 | 0 | |
29 | Landscaping | 6/27/2025 | 5 days | Start No Earlier Than | 6/27/2025 | 7/3/2025 | 28FS | 0 |
30 | Final Inspection | 7/7/2025 | 3 days | Must Finish On | 7/9/2025 | 7/9/2025 | 29FS+1 day | 0 |
31 | Correction of Issues | 7/10/2025 | 3 days | As Soon As Possible | 7/14/2025 | 30FS | 0 | |
32 | Final Walkthrough | 7/15/2025 | 2 days | As Late As Possible | 7/16/2025 | 31FS | 0 | |
33 | Handover Preparation | 7/17/2025 | 3 days | Start No Earlier Than | 7/17/2025 | 7/21/2025 | 32FS | 0 |
34 | Client Handover | 7/23/2025 | 2 days | Finish No Earlier Than | 7/24/2025 | 7/24/2025 | 33FS | 0 |
35 | Warranty Period Begins | 7/25/2025 | 2 days | As Soon As Possible | 7/28/2025 | 34FS | 0 | |
36 | Routine Maintenance Visits | 7/29/2025 | 10 days | As Late As Possible | 8/11/2025 | 35FS | 0 | |
37 | First Year Warranty Review | 8/12/2025 | 5 days | Start No Earlier Than | 8/12/2025 | 8/18/2025 | 36FS | 0 |
38 | Final Project Documentation | 8/20/2025 | 3 days | Finish No Earlier Than | 8/22/2025 | 8/22/2025 | 37FS | 0 |
39 | Celebrate Project Completion | 8/25/2025 | 3 days | As Soon As Possible | 8/27/2025 | 38FS | 0 | |
40 | Begin Next Project Planning | 8/28/2025 | 4 days | As Late As Possible | 9/2/2025 | 39FS | 0 |
Mar 25, 2025 | Mar 30, 2025 | Apr 06, 2025 | Apr 13, 2025 | Apr 20, 2025 | Apr 27, 2025 | May 04, 2025 | May 11, 2025 | May 18, 2025 | May 25, 2025 | Jun 01, 2025 | Jun 08, 2025 | Jun 15, 2025 | Jun 22, 2025 | Jun 29, 2025 | Jul 06, 2025 | Jul 13, 2025 | Jul 20, 2025 | Jul 27, 2025 | Aug 03, 2025 | Aug 10, 2025 | Aug 17, 2025 | Aug 24, 2025 | Aug 31, 2025 | Sep 07, 2025 | Sep 14, 2025 | Sep 21, 2025 |
---|
T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S | S | M | T | W | T | F | S |
---|
In Gantt Chart, task constraints define the rules that limit a task start or end date based on project scheduling needs. The following constraint types are supported:
As Soon As Possible
- Task starts as early as possible. Default for auto-scheduled tasks.As Late As Possible
- Task finishes as late as possible without delaying dependent tasks.Must Start On
- Task must start on the specified date.Must Finish On
- Task must finish on the specified date.Start No Earlier Than
- Task cannot start before the specified date.Start No Later Than
- Task must start on or before the specified date.Finish No Earlier Than
- Task cannot finish before the specified date.Finish No Later Than
- Task must finish on or before the specified date.
You can assign constraints to a task using the taskFields.constraintType
and taskFields.constraintDate
properties.
Constraints can also be updated interactively through the task edit dialog.
Handling constraint violation popup:
To control or suppress the constraint violation dialog, handle the actionBegin
event with requestType
as validateTaskViolation
.
Use args.validateMode
to specify how to respond to constraint conflicts. Available properties include:
respectMustStartOn
respectMustFinishOn
respectStartNoLaterThan
respectFinishNoLaterThan
These options are false by default, which means the violation popup appears. To suppress the popup and cancel conflicting changes silently, set the relevant flag(s) to true.