We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Unable to retrive Formfield

Hi,

I've used Aspose.pdf 6.5 for generating a pdf using XML,XSL method. I add the Text Formfield in the pdf using XML.I'm able to view the field in the PDF.when i'm trying the fetch the value from the Aspose.PDF or Aspose.PDF.Kit it is not showing the Formfield. I'm getting the Form elements count as zero.The same code was working fine with Aspose.pdf 5.5 and Aspose.pdf.Kit 5.5. Kindly help me.

Hi,<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

Please share the template files and sample code to help us generate the issue at our end. We will look into it and get back to you soon.

Thank You & Best Regards,

Hi,

I'm using the following code and template to generate pdf from Aspose.pdf 6.5

Pdf asposePDF = new Pdf();

asposePDF.BindXML(Server.MapPath(@"XML\Data.xml"), Server.MapPath(@"XML\AsposeSample.xslt"));

asposePDF.Save(Server.MapPath(@"Output\AsposePDF.pdf"));

Aspose.Pdf.Facades.Form pdfForm = new Form(Server.MapPath(@"Output\AsposePDF.pdf"));

string[] formFields = pdfForm.FieldNames;

Style Sheet Sample:

<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

<xsl:template match="text()" />

<xsl:template match="/Contents">

<Pdf xmlns="Aspose.Pdf">

<Section PageWidth="8.5inch" PageHeight="11inch" PageMarginLeft="75" PageMarginRight="75">

<Text ID="Header" MarginTop="10" Alignment="center">

<Segment>

Aspose Sample Coordinate StyleSheet using Aspose 6.5

</Segment>

</Text>

<FormField FormFieldType="Text" FieldName="userSign" FormWidth="200" FormHeight="19" ID="userSignature"></FormField>

<Text ID="signaturePart2" MarginTop="10" Alignment="center">

<Segment>

<FormField FormFieldType="Text" FieldName="userSign2" FormWidth="200" FormHeight="19" ID="userSignature2"></FormField>

</Segment>

</Text>

</Section>

</Pdf>

</xsl:template>

</xsl:stylesheet>

Hi,

Thanks for your interest in our products.

First of all, I apologize for the delay in the response. I tested the scenario and noticed the same problem. For rectification, I logged this problem with ID “PDFNEWNET-33130” in our Issue Tracking System. We will further look into the issue and will keep you updated via this forum thread.

We apologize for your inconvenience.

Thanks & Regards,