We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Every form field ends with "-0"

So I have the following VB.NET code that creates a form field in a PDF:

Dim pdfField As New Pdf.Interactive.PdfTextBoxField(pdfDoc.Pages(iPage), "txt1")
pdfField.Location = New PointF(50, 50)
pdfField.Size = New SizeF(100, 10)
pdfDoc.Form.Fields.Add(pdfField)

This works great except for one thing. When I open up the PDF in Acrobat and look at the field name I notice that it says "txt1-0". Now I can't figure out where the "-0" is coming from and how to get rid of it.

2 Replies

SW Steve Wortham September 23, 2009 07:03 PM UTC

Ah ha, I just found out what was causing this.

Previously I was using both the PdfLoadedDocument and PdfDocument classes. I was loading the PdfLoadedDocument into the PdfDocument via ImportPages and apparently this process will add the "-0" suffix to the field names.

I found that in my case I can get rid of the PdfDocument object and just use PdfLoadedDocument and that fixed it.


SS Sri Subhashini M Syncfusion Team September 24, 2009 09:47 AM UTC

Hi Steve,

Thank you for your interest in Essential PDF.

I was able to reproduce the issue which you mentioned here. We glad to let you know that the issue has been fixed and it is available with our latest development build.

Could you please download our latest development build from the below location and let me know if you need any information?

http://www.syncfusion.com/downloads/development-builds

Regards,
Suba

Loader.
Live Chat Icon For mobile
Up arrow icon