Articles in this section
Category / Section

How to avoid bitmapped output in PDF document while converting HTML using IE Rendering engine

1 min read

Avoid bitmapped output in PDF while converting HTML using IE Rendering engine

Step 1:

In IE based HTML to PDF converter, with IE 9 and above there is a known issue that it generates only raster image. You can get more information on this from the following link:

http://msdn.microsoft.com/en-us/library/ee330732(v=vs.85).aspx#iviewobject_draw

As explained, to solve this, the key FEATURE_IVIEWOBJECTDRAW_DMLT9_WITH_GDI should be updated in the registry.

Step 2:

  1. You can update the registry by include the below code snippet in your application before conversion takes place.

Microsoft.Win32.Registry.SetValue(

            @"HKEY_CURRENT_USER\SOFTWARE\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_IVIEWOBJECTDRAW_DMLT9_WITH_GDI",

            "*",

            1,

            Microsoft.Win32.RegistryValueKind.DWord);

 

Microsoft.Win32.Registry.SetValue(

            @"HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_IVIEWOBJECTDRAW_DMLT9_WITH_GDI",

            "*",

            1,

            Microsoft.Win32.RegistryValueKind.DWord);

 

Note:

Use the above code to enable the Legacy through C# code, and it is not mandatory to run this code each time before the HTML converter is used.

or

  1. Please run the utility placed in the following location with elevated permission to perform the above changes automatically.

$system drive:\Program Files\Syncfusion\Essential Studio\$Version # \Utilities\PDF\Legacy Drawing

Step 3:

After completed the step 2, please make sure that the FEATURE_IVIEWOBJECTDRAW_DMLT9_WITH_GDI at both HKEY_LOCAL_MACHINE and HKEY_CURRENT_USER is set as below?

Name

Type

Data

*

REG_DWORD

0x00000001

Step 4:

If you find any difficulty in using the Legacy tool or if the key is not properly updated in the registry you may add the key manually. Please find the video tutorial for this below.

https://www.syncfusion.com/downloads/support/directtrac/general/ze/IE9_RegistryEdit-497183743

Note:

This registry changes have to be made in the system or server where the conversion takes place.

 

Did you find this information helpful?
Yes
No
Help us improve this page
Please provide feedback or comments
Comments (0)
Please sign in to leave a comment
Access denied
Access denied