CSharp: Update to PDFXEDITORSDKPRO11

PDF-XChange Editor SDK for Developers

Moderators: PDF-XChange Support, Daniel - PDF-XChange, Chris - PDF-XChange, Sean - PDF-XChange, Paul - PDF-XChange, Vasyl - PDF-XChange, Ivan - Tracker Software, Stefan - PDF-XChange

Forum rules
DO NOT post your license/serial key, or your activation code - these forums, and all posts within, are public and we will be forced to immediately deactivate your license.

When experiencing some errors, use the IAUX_Inst::FormatHRESULT method to see their description and include it in your post along with the error code.
SHartmann
User
Posts: 4
Joined: Fri Jan 22, 2021 10:40 am

CSharp: Update to PDFXEDITORSDKPRO11

Post by SHartmann »

I failed to update from PDFEXeditorSDK10 to PDFEXeditorSDK11.
None of the .net samples works.

So I deinstalled everything, rebooted and reinstalled it.

I noticed some changes:

Installation now is in C:\Program Files (x86)\PDF-XChange instead of C:\Program Files (x86)\Tracker..


The DLL-Name has changed to PXCEditorCore.x64.dll instead of PDFXEditCore.x64.dll

none of them is reflected in the weblink (https://sdkhelp.pdf-xchange.com/view/Main_Page) in installationfolder.

The .net csharp FullDemo sample still don't work.

Error: System.InvalidCastException: 'Die angegebene Umwandlung ist ungültig.'

at MainFrm.cs line 541:
pxcInst = (PDFXEdit.IPXC_Inst)pdfCtl.Inst.GetExtension("PXC");

Stacktrace
at PDFXEdit.PXV_InstClass.GetExtension(String sName)
at FullDemo.MainFrm..ctor() in C:\Program Files (x86)\PDF-XChange\Editor SDK\Samples\CSharp\FullDemo\MainFrm.cs:line 541
at FullDemo.Program.Main() in C:\Program Files (x86)\PDF-XChange\Editor SDK\Samples\CSharp\FullDemo\Program.cs:line 20


during build I get a

Code: Select all

1>C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(3081,5): warning MSB3305: Processing COM reference "PDFXEdit" from path "C:\Program Files (x86)\PDF-XChange\Editor SDK\Bin\PXCEditorCore.x64.dll". Interface 'IAFS_FilesAutoConversionCallback' is marked as [dual], but does not derive from IDispatch. It will be converted as an IUnknown-derived interface.
1>C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(3081,5): warning MSB3305: Processing COM reference "PDFXEdit" from path "C:\Program Files (x86)\PDF-XChange\Editor SDK\Bin\PXCEditorCore.x64.dll". Interface 'IAFS_Dlg' is marked as [dual], but does not derive from IDispatch. It will be converted as an IUnknown-derived interface.
1>C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(3081,5): warning MSB3305: Processing COM reference "PDFXEdit" from path "C:\Program Files (x86)\PDF-XChange\Editor SDK\Bin\PXCEditorCore.x64.dll". The type library importer could not convert the signature for the member 'IXC_PageBlockData.pData'.
1>C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(3081,5): warning MSB3305: Processing COM reference "PDFXEdit" from path "C:\Program Files (x86)\PDF-XChange\Editor SDK\Bin\PXCEditorCore.x64.dll". At least one of the arguments for 'IPXS_PDFVariant.GetString_Unsafe' cannot be marshaled by the runtime marshaler.  Such arguments will therefore be passed as a pointer and may require unsafe code to manipulate.
1>C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(3081,5): warning MSB3305: Processing COM reference "PDFXEdit" from path "C:\Program Files (x86)\PDF-XChange\Editor SDK\Bin\PXCEditorCore.x64.dll". At least one of the arguments for 'IPXC_SecurityHandler.GetAuthData' cannot be marshaled by the runtime marshaler.  Such arguments will therefore be passed as a pointer and may require unsafe code to manipulate.
1>C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(3081,5): warning MSB3305: Processing COM reference "PDFXEdit" from path "C:\Program Files (x86)\PDF-XChange\Editor SDK\Bin\PXCEditorCore.x64.dll". Type library importer encountered a property getter 'TotalModifications' on type 'PDFXEdit.IPXC_DocSrcInfo' without a valid return type.  The importer will attempt to import this property as a method instead.
1>C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(3081,5): warning MSB3305: Processing COM reference "PDFXEdit" from path "C:\Program Files (x86)\PDF-XChange\Editor SDK\Bin\PXCEditorCore.x64.dll". The type library importer could not convert the signature for the member '_CERT_CONTEXT.pbCertEncoded'.
1>C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(3081,5): warning MSB3305: Processing COM reference "PDFXEdit" from path "C:\Program Files (x86)\PDF-XChange\Editor SDK\Bin\PXCEditorCore.x64.dll". The type library importer could not convert the signature for the member '_CERT_CONTEXT.pCertInfo'.
...
I noticed the manifest files in RegistrationFree folder also still mention wrong filenames

Code: Select all

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">

<assemblyIdentity
   type="win32"
   name="PDFXEditCore.x86.X"
   version="1.0.0.0" />

<file name = "PDFXEditCore.x86.dll">
Did I miss something that has changed ?

best regards
Stephan
User avatar
Sean - PDF-XChange
Site Admin
Posts: 1108
Joined: Wed Sep 14, 2016 5:42 pm

Re: CSharp: Update to PDFXEDITORSDKPRO11

Post by Sean - PDF-XChange »

Hi Stephan,

Yes, there were some changes when moving from V10 to V11. The path and executable changes are detailed here:

https://downloads.pdf-xchange.com/PathChanges.pdf

In addition to those, the following changes were made:

PDFXEdit.exe -> PXCEditor.exe
PDFXTools.exe -> PXCTools.exe
PDFXLocalizer.exe -> PXCLocalizer.exe

=== SDKs ===

Editor SDK:
PDFXEditCore.x64.dll -> PXCEditorCore.x64.dll
PDFXEditCore.x86.dll -> PXCEditorCore.x86.dll

Core API SDK:
PDFXCoreAPI.x64.dll -> PXCCoreAPI.x64.dll
PDFXCoreAPI.x86.dll -> PXCCoreAPI.x86.dll

Simple Edit SDK:
PDFXEditSimple.x64.dll -> PXCEditorSimple.x64.dll
PDFXEditSimple.x86.dll -> PXCEditorSimple.x86.dll

I hope that clarifies the situation for you, and I will mention to the development team that the link in the installation folder now goes to obsolete information - thanks for the feedback.

Kind regards,
Sean Godley
Technical Writer
PDF-XChange Co LTD
Sales: +1 (250) 324-1621
Fax: +1 (250) 324-1623
SHartmann
User
Posts: 4
Joined: Fri Jan 22, 2021 10:40 am

Re: CSharp: Update to PDFXEDITORSDKPRO11

Post by SHartmann »

From this changes I would expect that the csharp samples still work.
They don't work for me, and I did a fresh install.
Can you please look in these sample and confirm that they work on your side.
Maybe they need some adoption too (I have version 11.0.1, downloaded today)?


best regards

Stephan