Pdf margings and layout issues after upgrade from aspose.pdf 16.12.0.0 to 23.9.0 .NET c#

@souf123
The task will be closed in version 24.02
A new property HtmlLoadOptions.IsPriorityCssPageRule has been added.
You need to set it to true, then the @page rules defined in the css will override the values defined in PageInfo.
Сode example:

string inFile = "56373.html";
string outFile = "56373.pdf";
var options = new HtmlLoadOptions(url path of css files);
options.IsPriorityCssPageRule = true;
var pdfDocument = new Document(inFile, options);
pdfDocument.Save(outFile);

Thank you for your reply.
That seems great.
Is there an exact date when the version 24.02 will be available?

Thanks for your response

It should be today or tomorrow.

1 Like

The issues you have found earlier (filed as PDFNET-56373) have been fixed in Aspose.PDF for .NET 24.2.