Regarding EmfRenderSetting

When converting .xlsx to .pdf vis Aspose.Cells(JAVA), there are two options to render an emf image as follows.

  • [EMF_ONLY]
  • [EMF_PLUS_PREFER]
    Obviously, the above options work well without any issues.

However, In my industry, when preparing a document, emf and emf+ images may be in one .xlsx. In this case, in the current options, it seems that only one of the emf or emf+ is rendering on .pdf conversion now.

I wonder if you have any plans to support dual mode rendering.

@kpkim,

Yes, currently, using Aspose.Cells for Java, you can only specify one EMF rendering setting when rendering an Excel spreadsheet to PDF. We can investigate further and log a ticket for evaluation. However, could you please share a sample PDF document that has dual rendering mode for reference?

@kpkim ,

An EMF image can be EmfOnly, EmfPlusOnly and EmfPlusDual. When you set EmfRenderSetting.EMF_PLUS_PREFER, it should work OK for the three cases. For EMF image with EmfPlusDual, only records used by EMFPLUS are parsed in this case.

I attached a sample file.
testemfsample.zip (389.7 KB)

When I set pdfSaveopt up EMF_PLUS_PREFER as below, only first page emf image is rendered.
pdfSaveopt.setEmfRenderSetting(EMF_PLUS_PREFER);
When I set pdfSaveopt up EMF_ONLY, only second page emf image is rendered.
pdfSaveopt.setEmfRenderSetting(EMF_ONLY);

Can you review the above with attached files?

@kpkim
We can reproduce the issue as you mentioned, only first page emf image is rendered when EMF_PLUS_PREFER is set, but only second page emf image is rendered when EMF_ONLY is set.
We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.

Issue ID(s): CELLSJAVA-45741

You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.

@kpkim

Because the Emf imag in the first sheet doesn’t contain data in EmfOnly records, so the image will be rendered only when EmfRenderSetting.EMF_PLUS_PREFER is set.
Both of the two Emf images will be rendered in the coming fix/release with EmfRenderSetting.EMF_PLUS_PREFER be set.

This is to inform you that your two issues (“CELLSJAVA-45741”) have been resolved. The fixes will be included in our upcoming release (Aspose.Cells v23.12) that we plan to release in the second week of December. You will be notified when the new version is published.

The issues you have found earlier (filed as CELLSJAVA-45741) have been fixed in Aspose.Cells for Java 23.12.