Hi,
I'm testing the new DynamicPDF for .Net version v8.x on my applications to upgrade the v4.x currently used. I have an Issue with some PDF documents:
when I try to read the acrofields used in the document, the v4.x dll does it and fills the fields without problem, with the v8.x version the application throws an Object reference exception (Pdf.Form is Null). With other documents the _pdf.Form is of type {ceTe.DynamicPDF.Merger.Forms.PdfForm}.
All PDF used are correctly viewed with Acrobat Reader and Acrobat Professional and all acrofields are viewed and recognized.
Some documents are correctly read with v4 version and throw exception with v8. The Object reference exception is thrown because the .Form object of the document is null in v8 version and correctly read in v4.
A simple code that explains that:
try
{
string _myFolder = <folderpath>;
string [] _fileList = Directory.GetFiles (_myFolder, "*.pdf");
foreach ( string _f in _fileList )
{
PdfDocument _pdf = new PdfDocument (_f);
try
{
// -->> this code throws an exception with v8 and not with v4
MessageBox.Show (_pdf.Form.Fields [0].FullName);
// -->> this code displays "no form" with v8 and the first
// -->> field name with v4
if ( _pdf.Form != null )
{
MessageBox.Show (_pdf.Form.Fields [0].FullName);
}
else
{
MessageBox.Show ("no form in document");
}
}
catch (Exception exc)
{
MessageBox.Show (exc.Message);
}
}
}
catch
{
throw new Exception ("some other exception");
}
Do you already know this issue?
Thank you in advance
Graziano Aldrovandi
Acrofields not recognized
Re: Acrofields not recognized
Support · Nov 18, 2014Hello Graziano,
We are not aware of this issue and we would need to investigate further. Please email some of the PDF forms that work in v4 and throw an error in v8 to [^a|mailto:support@cete.com|opennewwindow|support@cete.com^] and refer to this forum post url in your email.
Thanks,
ceTe Software Support Team.
Re: Acrofields not recognized
Support · Nov 25, 2014Hello,
This issue has been fixed in the latest build. Please contact us at [^a|mailto:support@cete.com|opennewwindow|support@cete.com^] to get the latest dlls.
Thanks,
ceTe Software Support Team.