Hi BGomes,
The error can be rectified by putting AspCompat=”true” in page directive. Could you please do the following steps.
Here are some steps for your clarification.
1) Add to the @Page directive AspCompat="true" attribute to the page where we want to perform html to pdf convertion.
2) Reference the "AxInterop.dll and SHDocVw.dll" assembly to the project.
Here is the sample for your reference.
HTML_TO_PDF_CS_2005.zip
Could you please take a look at this and let me if you have any other queries.
Regards,
Prakash.