Some test text!
With versions of Visual Studio since 2008, Microsoft no longer allows statically linking to the CRT for .NET components. To get everything working, installing the VC++ runtime is not necessary, instead required DLLs can simply be copied into the same folder where PDFNet.DLL is located. There is no dll registration needed.
See this Microsoft guide on deployment options for the VC++ runtime redistributables.
If in doubt when using an older version, a utility called Dependency Walker can help you to identify which two DLLs are required.
This issue is most likely caused by missing VC++ Runtime redistributables, which can either be installed on the OS, or packaged with your app.
See above for links to correct VC++ runtime.
If there is some still some reason your require using .NET 2 assembly, the following article might help. http://stackoverflow.com/questions/3179028/mixed-mode-assembly-in-net-4
This error generally means that GDI+ is missing/blocked by your OS, e.g. Windows Nano Server. PDFNet on Windows requires GDI+ for loading fonts, so to resolve this issue please upgrade to a server environment that allows access to GDI+.
For Azure Function the default settings block GDI+, but it is possible to reconfigure Azure Function to work. For example, one possible solution is to change the Function App hosting plan from "Serverless Consumption Plan" to the "App Service Plan" with a Basic server, for instance. Azure support should be able to assist you in getting GDI+. Or alterntively, switch to Linux based Azure Function.
If you are using a direct reference to
PDFNet.dll, please ensure that your reference is pointing to the correct version
32-bit vs 64-bit of the
PDFNet dll. Also check and ensure that
copylocal is set to true for the assembly reference in the project.
Or see the guides above to make sure you have the required VC++ and GDI dependencies.
Get the answers you need: Support
Get unlimited trial usage of PDFTron SDK to bring accurate, reliable, and fast document processing capabilities to any application or workflow.
Select a platform to get started with your free trial.
Unlimited usage. No email address required.