New to Telerik Reporting? Download free 30-day trial

Images are Shrunk in DOCX, XLSX, PPTX formats on Mac machines

Environment

Product Progress® Telerik® Reporting
OS MacOS
Rendering Extensions DOCX, XLSX, PPTX

Description

The Graph, Map and Barcode items are rendered as EMF in OpenXML formats like DOCX, XLSX, PPTX. On Mac machines, the images may appear shrunk.

Solution

To avoid the issue, you can force the rendering engine to create Bitmap images instead of EMF by setting the corresponding rendering extension's UseMetafile parameter.

For .NET Framework projects

<!-- web.config/app.config -->
<configuration>
    <configSections>
        <section
                name="Telerik.Reporting"
                type="Telerik.Reporting.Configuration.ReportingConfigurationSection, Telerik.Reporting, Version=x.x.x.x, Culture=neutral, PublicKeyToken=a9d7983dfcc261be"
                allowLocation="true"
                allowDefinition="Everywhere"/>
    </configSections>
<Telerik.Reporting>
        <extensions>
            <render>
                <extension name="DOCX">
                    <parameters>
                        <parameter name="UseMetafile" value="false"/>
                    </parameters>
                </extension>
            </render>
        </extensions>
    </Telerik.Reporting>
    …
</configuration>

For .NET Core projects:

"telerikReporting": {
    "extensions": [
      {
        "name": "DOCX",
        "parameters": [
          {
            "Name": "UseMetafile",
            "Value": "false"
          }
        ]
      }
    ]
  }

Notes

The DOCX/PPTX/XLSX rendering extensions require the Telerik.Reporting.OpenXmlRendering.dll and the Open XML SDK 2.0 for Microsoft Office(DocumentFormat.OpenXml.dll v.2.0.5022.0 or above with proper binding redirects).

See Also

Telerik Reporting Configuration Section

Extensions Element

PPTX rendering extension's parameters

DOCX rendering extension's parameters

XLSX rendering extension's parameters

In this article