TerraFluent.Chart.Reporting

Gantt Chart in C#

Generate Gantt charts in C# with AddGantt and GanttTask — task bars on a time axis, per-task colours, rendered as self-contained SVG for reports and PDFs.

Gantt / Timeline

AddGantt() — horizontal task bars on a numeric time axis.

Project Sprint Timeline — AddGantt() — tasks on numeric day axis Project Sprint Timeline — AddGantt() — tasks on numeric day axis — Series: Sprint 1. Project Sprint Timeline AddGantt() — tasks on numeric day axis Requirements UI Design Backend Dev Frontend Dev Integration QA Testing Deployment 0 6 12 18 24 30 Req Design Backend Frontend Integ. QA Deploy Requirements: 0–5: 5 UI Design: 3–9: 6 Backend Dev: 6–18: 12 Frontend Dev: 9–20: 11 Integration: 17–23: 6 QA Testing: 20–27: 7 Deployment: 26–30: 4 Sprint 1 terrafluent.dev terrafluent.dev

When to use a gantt chart

Reach for it when

  • Project schedules and release plans, where overlap between tasks is what the reader is checking.
  • Resource and occupancy timelines — anything with a start, an end, and a name.
  • Embedding a schedule into a generated PDF or Word status report.

Use something else when

  • Dependency networks. A Gantt shows position, not "B cannot start until A finishes".
  • Very many tasks — past thirty rows it becomes a wall; group or filter first.
  • Plans that change hourly, where a rendered snapshot is stale before it is read.

Gantt Chart in C#

Lifted verbatim from the chart types reference, so it compiles against the shipped API. See the API reference for every overload and the exact data types each series method accepts.

using TerraFluent.Chart.Reporting.Models;

string svg = ChartBuilder.Create()
    .Title("Release Plan (weeks)")
    .Size(760, 380)
    .XAxis(x => { x.Title = "Week"; x.Min = 0; x.Max = 12; })
    .AsAnimated()
    .Series(s => s
        .AddGantt("Schedule", new[]
        {
            new GanttTask { Name = "Design",      Start = 0, End = 3 },
            new GanttTask { Name = "Development",  Start = 2, End = 8, Color = ChartColor.ChartBlue },
            new GanttTask { Name = "Testing",      Start = 7, End = 10 },
            new GanttTask { Name = "Launch",       Start = 10, End = 12, Color = ChartColor.ChartGreen },
        }))
    .RenderToSvg();

Install

dotnet add package TerraFluent.Chart.Reporting
  • MIT licensed — free for commercial use, no chart limits, no watermarks.
  • Zero dependencies — nothing but the .NET base class library.
  • netstandard2.0 through net10.0 — .NET Framework 4.6.1+, .NET Core 2.0+, and every modern release.
  • Output is one SVG string — embed it in HTML, a PDF, or a Word document.