Search

Atalasoft Knowledge Base

HOWTO: Specify a Custom Extraction location for Atalasoft.Pdfium.dll (resolve PdfDecoder issue)

Tananda
DotImage

Applicability

This article applies to version 11.0 and newer as the Pdfium engine has additional dlls that are auto exttacted from Atalasoft.dotImage.PdfReader.dll 

If you're running into issues in either a web or console or desktop app where there is an error about temp file access / missing Atalasoft.Pdfium.dll, this may be a permissions issue where the process is unable to extract due to insufficient rights. This almost never affects desktop users or other processes running under an interactive domain or user account as the default location is in the user temp directory

However, for process that run as a system service, the "user temp directory" doesn't apply and those may try to use restricted system temp locations. This is especially problematic for web processes.

How To Manually Specify Extraction Location

Controlling where the PdfIum dll extracts to is sometimes required

This is known behavior:

https://www.atalasoft.com/KB2/KB/50058/INFO-Changes-Introduced-in-DotImage-110

under

TempFile Extraction for Atalasoft.PdfIum.dll

The good news is that in newer versions (11.0.0.9 and newer) there is an explicit way to configure where to look..

Check out the PdfDecoder API reference:

To configure Pdfium library location, you should add the next line to app.config file:

Copy<Atalasoft>

<PdfDecoder PdfiumLocation="C:\Folder\Subfolder\SubSubFolder"/>

<!-- Components sections -->

...

</Atalasoft>

You can also use a relative path

Copy<Atalasoft>

<PdfDecoder PdfiumLocation="..\Another\Sub\Folder"/>

<!-- Components sections -->

...

</Atalasoft>

you'll need to update your web.config to point it at a valid location where it can extract under the web process's credentials.. the sample here was for app.config.. it needs to be altered for web.config.. this is a general guidance based on

http://www.atalasoft.com/docs/dotimage/docs/html/T_Atalasoft_Shared_AtalasoftConfigSection.htm

 

<?xml version="1.0"?> 
<configuration> 
    <configSections> 
        <section name="Atalasoft" type="Atalasoft.Shared.AtalasoftConfigSection, Atalasoft.Shared"/> 
    </configSections> 
    <runtime> 
        <gcServer enabled="true"/> 
    </runtime> 
    <Atalasoft> 
        <PdfDecoder PdfiumLocation="C:\SomePath\SimpleWDVwithWDT\SimpleWDVwithWDT\bin"/> 
    </Atalasoft> 
    <system.web> 
        ... removed for brevity here... 
    </system.web> 
</configuration> 

Details
Last Modified: 4 Months Ago
Last Modified By: Tananda
Type: HOWTO
Article not rated yet.
Article has been viewed 161 times.
Options
Also In This Category