Jason Z
Jason Z

Reputation: 13432

Business reporting with per-page print control

Does anyone know of a reporting tool that allows for controlling the print job on a page by page basis? Specifically, I need to be able to insert escape sequences to the printer.

The closest I have found is ActiveReports. It provides an interface like this:

SystemPrinter sp = new SystemPrinter(); 
sp.StartJob("jobname"); 
foreach(Page pg in rpt.Pages) { 
    sp.Escape("escape_characters"); 
    sp.StartPage(); 
    pg.Draw(sp.Graphics, rect); //render page to printer
    sp.EndPage(); 
} 
sp.EndJob(); 

The problem is that their escape function has a known bug and does not properly pass the escape characters to the printer.

An interface similar to this is ideal, but not necessary. The minimum requirements that I have to deal with is to send different commands to the printer on a per page basis. I am also working in .NET. Any suggestions would be appreciated. Thanks.

Upvotes: 0

Views: 1505

Answers (2)

Scott Willeke
Scott Willeke

Reputation: 9345

I am pretty sure you will find that ActiveReports is the only report writer that provides such extensible control over print jobs, especially providing escape support. Surely, if I'm wrong, someone will correct me. What is the bug with Escape that you're running into? It is also worth noting that Windows itself has starting introducing some limitations with escape since Windows 9x was introduced and microsoft has discouraged using escapes ever since Windows 9x started. Just one source from Microsoft that mentions this is KB125692. Anyway, tell me more about what problems you're facing with escape and I'll try to either get the bug resolved or find you a workaround.

-scott

Upvotes: 1

Paul Lefebvre
Paul Lefebvre

Reputation: 6406

Sorry, the best one I've worked with is ActiveReports. If there's a known bug, then definitely report it to them. I've found they have decent support.

Upvotes: 1

Related Questions