Page 1 of 1

Problem with PrintToDotMatrixPrinter

Posted: Fri Jan 17, 2014 10:13 am
by PJoyeux
Hi,

when I use the preview-tab of objStiWpfDesignerControl, then call the DotMatrixPreview and then use the print button to print on a MatrixPrinter the report is printed correctly.

But when I user StiReport.PrintToDotMatrixPrinter(...) the output has many completely superfluous LF/CR in front and after the actual report. This leads to 10 or more pages that are fed through the printer after the report!!!

I have made HexDumps of the codes that are sent to the printer once printing directly and once printing via preview. I have then scanned those HexDumps (see PDF Files attached). The report is attached too (simple as can be, just "Test").

The printers are installed as "Generic" and I don't think this is a problem of the driver anyhow, since it works perfectly when printed from the preview.

This is the code I use to print the report directly.

Code: Select all

objReport.LoadFromString(sReportDefition);
objReport.Render();
objReport.PrintToDotMatrixPrinter(aPrinter, System.Text.Encoding.GetEncoding(1252), false, Stimulsoft.Report.Export.StiTxtBorderType.Simple, false, false, false, false, 100, 100, 1, objReport.RenderedPages.Count, true, "EpsonFX");
The only difference ist that I set some variables and register some BusinessObjects before printing directly which of course I can't do printing from the preview. But none of those variables and/or BusinessObjects are used within this Test-Report.

Any idea?

Cheers,
Pascal

Re: Problem with PrintToDotMatrixPrinter

Posted: Fri Jan 17, 2014 2:21 pm
by HighAley
Hello.

Sorry for the delay with answer. We need some additional time.

Thank you.

Re: Problem with PrintToDotMatrixPrinter

Posted: Mon Jan 20, 2014 7:55 am
by HighAley
Hello.

The zoomX and zoomY parameters should be 1. We will add this note to our documentation to avoid this problem again.

Thank you.

Re: Problem with PrintToDotMatrixPrinter

Posted: Wed Jan 22, 2014 12:26 pm
by PJoyeux
Oh boy... This really helped, I would never have figured this out by myself...

THANKS!

Re: Problem with PrintToDotMatrixPrinter

Posted: Wed Jan 22, 2014 12:57 pm
by HighAley
Hello.

We are always glad to help you.
Let us know if you need any additional help.

Thank you.