Dwg to Pdf adds a blank page at end after upgrade from Aspose.CAD 21.9.0 to 22.8.0

When converting a .dwg file, a blank page is added at the end of the generated pdf file. This started happening after upgrading C# library Aspose.CAD from 21.9.0 to 22.8.0
Attached are the input file, old (expected) output and new (undesired) file.
Files.zip (121.3 KB)
As far as the code goes, I tried different PdfOptions but the issue remained even after I stripped it down to basics with only required parameters:

using (var image = Image.Load(“input.dwg”))
{
var pdfOptions =
new PdfOptions
{
VectorRasterizationOptions =
new CadRasterizationOptions
{
PageWidth = 842,
PageHeight = 595,
}
};
image.Save(“output.pdf”, pdfOptions);
}

@PM88,
Hello, as I can see, version 22.7 is free of this issue with empty pages, you may use it. The fix for this problem will be available in 22.11.

1 Like