Introduction
ReoGrid 4.6 was released on October 16, 2026. It is a release about output: a worksheet now goes straight to a PDF file, and printed pages carry the headers, footers and page fitting that a business report needs. In the grid itself, the cell editor now edits rich text, so users can make one word bold without touching the rest of the cell.
ReoGrid V4 continues to be sold and supported alongside ReoGrid One V5, on the same license. This article walks through what 4.6 adds.
Key Highlights
- PDF export (WinForms): one call writes a worksheet, or a whole workbook, to PDF — paginated exactly as it prints
- Rich-text cell editor (WinForms / WPF): select part of the text while editing and make it bold, italic, colored or a different size
- Printed headers and footers: page numbers, page count, date, sheet name, with a different first page or odd/even pages
- Fit to pages and centering: Excel’s “Fit to” option, and centering the content on the page — for both printing and PDF
- XLSX page setup round-trip: paper size, scale, fit to pages, centering and the print area are read from and saved to Excel files
- Development-device license activation for newly issued Professional keys — keys you already have keep working as-is
PDF Export
PDFExporter.Export writes a worksheet — or several, as one document — to a PDF file or a stream.
using unvell.ReoGrid.PDF;
// One worksheet
PDFExporter.Export(reoGridControl.CurrentWorksheet, @"C:\Reports\sales.pdf");
// The whole workbook, one sheet after another
PDFExporter.Export(reoGridControl.Worksheets, @"C:\Reports\book.pdf");
// To memory, e.g. for an email attachment
using var ms = new MemoryStream();
PDFExporter.Export(reoGridControl.CurrentWorksheet, ms);
The PDF is paginated by the same rules as printing. Page breaks, paper size, margins, scaling, page order, and the header and footer all carry over, so each printed page becomes one PDF page and the file matches what the printer produces.
- Sharp at any zoom. Cells, borders and text are written as vector graphics and real text, so the file can be searched, and its text selected and copied.
- Small files. Only the glyphs a document uses are embedded — a Japanese font adds tens of kilobytes rather than megabytes. Text the cell’s font cannot display falls back to a CJK-capable font, as it does on screen.
- What it carries. Cell fills, every border style, cell text (rotated text, and wrapped or multi-line text broken with Japanese line-breaking rules), row and column headers, and images.
- Built in. Everything PDF output needs ships inside ReoGrid, so the export completes without an additional library — the product is still a single DLL.
Like printing, PDF export requires a valid license key, and throws InvalidOperationException without one.
Need PDFs on a server?
PDFExporterbelongs to the WinForms edition. To render PDFs headless — in an ASP.NET Core service, a batch job, or a Linux container — use ReoGrid One V5, which the same license also covers.
Rich-Text Cell Editor
The plain text box that used to edit cells is replaced by an editor that edits the cell’s rich text directly.
- Select part of the text while editing and press Ctrl+B / Ctrl+I / Ctrl+U, or apply bold, italic, underline, strikethrough, a font, a size or a text color from your own toolbar
- Content with mixed formatting is saved as
RichText; content formatted uniformly stays plain text with the cell style — as in Excel - The editor grows to fit its content, follows center and right alignment, selects a word on double-click (dragging then extends by words), and places the IME composition window at the caret
- While a formula is being edited, each reference is colored in the editor text with the same color as its frame on the grid. Point-mode reference picking from 4.5 works in the new editor
To wire a toolbar button so it styles the selected text while a cell is being edited, and the selected cells otherwise, call ApplyStyleToEditingTextSelection first:
using unvell.ReoGrid;
using unvell.ReoGrid.Actions;
private void ApplyTextStyle(WorksheetRangeStyle style)
{
var sheet = reoGridControl.CurrentWorksheet;
// true: applied to the text selected in the cell editor
if (sheet.ApplyStyleToEditingTextSelection(style)) return;
// otherwise the style belongs to the cells
reoGridControl.DoAction(new SetRangeStyleAction(sheet.SelectionRange, style));
}
private void boldButton_Click(object sender, EventArgs e)
{
ApplyTextStyle(new WorksheetRangeStyle
{
Flag = PlainStyleFlag.FontStyleBold,
Bold = boldButton.Checked,
});
}
ApplyStyleToEditingTextSelection returns false when the style belongs to the cell rather than to part of its text — no editing session, nothing selected, a full selection over uniformly formatted text, or a formula. Changing the style keeps the editing session open, including while a toolbar dropdown such as a color picker has the focus.
Printing: Headers and Footers
Pages printed through a print session (WinForms print and print preview), and pages exported to PDF, now carry the worksheet’s header and footer. They use Excel’s format codes, and they are read from and saved to XLSX files.
var sheet = reoGridControl.CurrentWorksheet;
// "Monthly report" on the left, "Page 2 of 5" on the right
sheet.HeaderFooter.OddHeader = "&LMonthly report&RPage &P of &N";
// The sheet name, centered
sheet.HeaderFooter.OddFooter = "&C&A";
// A different header on the first page
sheet.HeaderFooter.DifferentFirst = true;
sheet.HeaderFooter.FirstHeader = "&CQuarterly sales report";
| Code | Prints |
|---|---|
&L / &C / &R | Starts the left / center / right section |
&P / &N | Page number / total pages |
&D / &T | Date / time |
&A | Sheet name |
&& | A literal & |
The distance from the paper edge to the header and footer is set with PrintSettings.HeaderMargin and FooterMargin, in inches (0.3 by default, as in Excel). Odd/even pages (DifferentOddEven), scaling with the page (ScaleWithDocument) and alignment with the margins (AlignWithMargins) are honored too.
The header and footer print on one line in the sheet’s default font, in black. Excel’s font, size and color codes inside the text are skipped, and pictures in headers (&G) are not printed.
Printing: Fit to Pages and Centering
PrintSettings.FitToPage shrinks the printable range into a given number of pages, like Excel’s Fit to option. It only ever shrinks — a sheet that already fits prints at 100%.
var ps = sheet.PrintSettings;
// One page wide, as many pages tall as it takes
ps.FitToPage = true;
ps.FitToPagesWide = 1;
ps.FitToPagesTall = 0; // 0 = no limit in that direction
// Center the content on each page
ps.CenterHorizontally = true;
// Recalculate the page breaks for the new settings
sheet.AutoSplitPage();
Both settings apply to WinForms printing and print preview, and to PDF export. As in Excel, Fit to ignores manual page breaks.
XLSX Page Setup Round-Trip
The page setup of an Excel file is now read and saved: paper size, page scale, fit to pages, page order, centering, printed grid lines, and the print area, along with the header, footer and page margins.
Before 4.6, a sheet printed on Letter paper at 100% over its whole used range regardless of the file, a portrait sheet was loaded as landscape, and the header, footer and margins were lost on save. A workbook laid out for printing in Excel now prints from your application the way it was designed.
Other Fixes
- Printing: cell text no longer loses its last character, and wrapped text wraps at the width of the cell, as in Excel
- Printing / PDF: pictures and shapes on the screen stay in place after printing, print preview or PDF export at a page scale other than 100%
- Rich text: rich-text cells draw faster, with the same character spacing as the same text in a plain cell (WinForms)
- License: a trial key is read correctly on a machine that uses a non-Gregorian calendar, such as the Thai Buddhist calendar, and its deadline no longer shifts with the time zone
Behavior Changes
- The rich-text editor replaces the plain text-box editor on both WinForms and WPF. Ctrl+Z inside the editor (the text box’s single-level undo) is not available yet. It is on the roadmap.
- On WPF, the editor is no longer exposed to UI Automation as a text box, so an automated UI test that typed into the old editor needs adjusting.
Also since 4.5: Choosing How Sheets Load (4.5.1)
4.5.1, released in July, made the sheet loading strategy for multi-sheet XLSX files a choice of your own:
// Default: every sheet is parsed during Load, as in 4.4 and earlier
reoGridControl.WorksheetLoadStrategy = WorksheetLoadStrategy.LoadAll;
// Parse the active sheet now, and the others on first access
reoGridControl.WorksheetLoadStrategy = WorksheetLoadStrategy.DelayLoad;
// Like DelayLoad, while a background task preloads the remaining sheets
reoGridControl.WorksheetLoadStrategy = WorksheetLoadStrategy.BackgroundDelayLoad;
reoGridControl.Load(@"C:\Data\book.xlsx");
Set it before calling Load. BackgroundDelayLoad opens a large workbook as fast as DelayLoad, while switching tabs usually finds the sheet already loaded.
Licensing: Development-Device Activation
Starting with 4.6, each newly issued Professional license key is assigned to one development device. License keys you already have keep working as-is.
- Running ReoGrid in a development environment requires authentication with a license key. You can download your license key from the customer portal.
- The applications you build and distribute are not part of this check: they run on your users’ machines exactly as before.
How to Upgrade
The latest 4.6 assemblies are available from the customer portal. Replace the referenced assemblies with the new version; your existing license key and your ReoGridLicense.SetLicense call stay as they are.
Closing
ReoGrid 4.6 turns a worksheet into a finished document — a PDF, or printed pages with headers, footers and the right fit — and gives end users Excel’s partial text formatting right in the cell.