FormulaEngineer examples
Create, read, and style Excel workbooks in .NET.
Style workbooks as you write them — fonts, fills, borders,
number formats, alignment, and layout — using
ExcelStyledWriter. Every example below is a complete,
runnable snippet.
Group
Cells and text
10
Layout
10
Conditional formatting
6
Named styles and themes
4
Tables and notes
10
Images and shapes
4
Charts and sparklines
6
Dashboards
4
Example
4
examples
in Images and shapes
Rounded rectangle callout
EnableShapesDraws a single rounded rectangle carrying text — a callout that floats above the grid rather than occupying cells, useful for annotating a generated report.
Write.cs
using FormulaEngineer.Api;
using FormulaEngineer.Api.Styling;
var stylingOptions =
new ExcelStylingOptions
{
EnableShapes = true
};
using (var writer = new ExcelStyledWriter("rounded-rectangle-callout-shape.xlsx", null, stylingOptions))
{
using (var sheet = writer.CreateWorksheet("Callout"))
{
sheet.WriteRow("Dashboard note");
sheet.AddShape(
ExcelShape.Create(
ExcelShapeKind.RoundedRectangle,
ExcelDrawingAnchor.OneCell(
column: 3,
row: 3,
widthPixels: 220d,
heightPixels: 80d),
text: ExcelShapeText.Create("Review complete"),
name: "Review callout"));
}
writer.Close();
}
Style your own workbooks
Styling is part of the same package — no separate install, no Excel, no COM automation.