Counter-increment is not working when convert from HTML to PDF

Hi there,
I have a HTML file with some css styles relating to Counter-increment, it works fine when opened by browser.
But when I converted from html to PDF, I got an exception:
System.ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection

Here is my test file
sample.html.zip (1.6 KB)
Please reply me if you have any information on this.
Thank you.

@tudinh

Thank you for contacting support.

We have been able to reproduce ArgumentOutOfRangeException which appears to be a file specific problem. Would you please elaborate if same exception occurs for every file containing counter-increment or with specific HTML files only, So that we may proceed further to help you out.

Hi,
The exception doesn’t appears every file containing counter-increment. It appears when the first

  • tag has siblings
  • and in its siblings have children
  • tag, I made my test file shorter, there are 2 file, 1 with exception and 1 run successfully:
    test.zip (2.9 KB)
    Please inform me if you need any further information.
    Thank you.
  • @tudinh

    Thank you for elaborating it further.

    We have logged a ticket with ID PDFNET-45716 in our issue management system for further investigation and resolution. The ticket ID has been linked with this thread so that you will receive notification as soon as the ticket is resolved.

    We are sorry for the inconvenience.

    1 Like