SAP Knowledge Base Article - Public

2147740 - Using a SATO CG 212 printer generates an error - "Specified method is not supported" when using the CopyFrom .NET API


A NotSupportedException with the message "Specified method is not supported." is thrown by CrystalDecisions.CrystalReports.Engine.ReportDocument.PrintOptions.CopyFrom when used with a SATO CG212 printer.

For example:

CrystalDecisions.CrystalReports.Engine.ReportDocument report = new CrystalDecisions.CrystalReports.Engine.ReportDocument();


PrinterSettings printerSettings = new PrinterSettings();

printerSettings.PrinterName = "SATO CG212";

MessageBox.Show("Will perform CopyFrom...", this.Text);

report.PrintOptions.CopyFrom(printerSettings, printerSettings.DefaultPageSettings); // The error occurs here

MessageBox.Show("Done.", this.Text);


Crystal Reports for Visual Studio

Reproducing the Issue

  1. Download the SATO CG212 printer driver located here: drivers.aspx
  2. Install the CG212 print driver to either NUL: or LPT1:. You do *not* need the actual printer.
  3. Ensure the name of the printer is "SATO CG212"
  4. Run SATO_PrinterTest.exe in the attached file.
  5. Click Test.
  6. "Will perform CopyFrom..." will appear, click OK.

    Note: "Specified method is not supported." is Expected:
  7. "Done."


The CopyFrom Method uses the DefaultPageSettings to set the values in the report.

For this printer when CR queries the System.Drawing.Printing.PaperSource property it is set to:

  • Kind = 0
  • RawKind = 0
  • SourceName = "Unknown"

For other typical drivers this value looks like this:

  • Kind = FormSource
  • RawKind = 15
  • SourceName = "automatically Selected"


Due to the SATO driver not setting this collection to the typical settings this generates the above error which is returned to Crystal by the OS System.

This is not a Crystal Reports for Visual Studio issue. Report the problem to SATO.

A work around is to use RAS to update the printer info as selected using the POC to update the printer info:

newOptsCloned.PageMargins.Bottom = 0;
newOptsCloned.PageMargins.Left = 0;
newOptsCloned.PageMargins.Right = 0;
newOptsCloned.PageMargins.Top = 0;

rptClientDoc.PrintOutputController.ModifyPrinterName("SATO CG212");
rptClientDoc.PrintOutputController.ModifyUserPaperSize(newOptsCloned.PageContentHeight, newOptsCloned.PageContentWidth);
rptClientDoc.PrintOutputController.ModifyPageMargins(newOptsCloned.PageMargins.Left, newOptsCloned.PageMargins.Right, newOptsCloned.PageMargins.Top,


NOTE: above code is not complete and only is to show you typically how to use the POC to modify the printer selected.


Crystal reports for visual studio, crforvs, Specified method is not supported, CopyFrom, SATO , KBA , BI-DEV-NET , BI Software Development Kits (SDKs) - .NET or Other , Problem


SAP Crystal Reports, developer version for Microsoft Visual Studio