Spire.PDF is a professional PDF library applied to creating, writing, editing, handling and reading PDF files without any external dependencies. Get free and professional technical support for Spire.PDF for .NET, Java, Android, C++, Python.

Tue Jun 01, 2021 12:58 pm

Hi,

I am trying the library Spire.PDF Free in vb.NET.

I am trying to write each fields in the attached PDF. I know it's a XFA Form and that it is mostly not supported any more but I have little choice because it comes from "high instance".
For testing, here is that I try to do : I basically try to write the name of each field in the value of the field if it's a XfaTextField or a "1" if it's a XfaIntField. I also print the name and type of the field in console.

Code: Select all
  Private Shared Sub TestWritePDF(source as String)
      Using pdf As New Spire.Pdf.PdfDocument(source)
        Dim theForm = DirectCast(pdf.Form, Spire.Pdf.Widget.PdfFormWidget).XFAForm
        WriteNameInAllFields(theForm)
        pdf.SaveToFile(dest)
        pdf.Close()
      End Using
  End Sub

  Private Shared Sub WriteNameInAllFields(theForm As Spire.Pdf.Widget.XFAForm)
    For Each name As String In theForm.Fields
      Console.WriteLine($"Name: '{name}', type: '{theForm.getField(name).GetType.ToString}'")
      If TypeOf theForm.getField(name) Is Widget.XfaTextField Then
        DirectCast(theForm.getField(name), Widget.XfaTextField).Value = name
      ElseIf TypeOf theForm.getField(name) Is Widget.XfaIntField Then
        DirectCast(theForm.getField(name), Widget.XfaIntField).Value = 1
      End If
    Next
  End Sub


But there is nothing written on the second page. I have no idea why? I this a limitation of the free version? Or if not what is the problem?

Thanks.
Best regards.

jeremyc87
 
Posts: 3
Joined: Tue Jun 01, 2021 12:46 pm

Wed Jun 02, 2021 9:26 am

Hello,

Thanks for your inquiry.
I tested your case and did reproduce your issue, I have logged it in our bug tracking system with the ticket SPIREPDF-4348. If there is any update, we will let you know. Apologize for the inconvenience caused.
If you have any other questions, please feel free to contact us.

Sincerely,
Brian
E-iceblue support team
User avatar

Brian.Li
 
Posts: 1271
Joined: Mon Oct 19, 2020 3:04 am

Thu Jun 03, 2021 6:25 am

Hi,

Thanks for you answer. Did you have any idea how much time this can take?
Because, my application have to be operational in 2-3 weeks. Can I expect a fix in time?

Thanks.
Best regards.

jeremyc87
 
Posts: 3
Joined: Tue Jun 01, 2021 12:46 pm

Thu Jun 03, 2021 9:32 am

Hello,

Thanks for your follow up.
We are very sorry that we can’t give you an estimated time at this moment. Our Dev team will investigate further and fix it. Anyway, we will notify you as soon as there is any progress.
Besides, please kindly note that we only update the free version irregularly. All new features and bug fixes are included in the commercial version first. Apologize for the inconvenience caused.

Sincerely,
Brian
E-iceblue support team
User avatar

Brian.Li
 
Posts: 1271
Joined: Mon Oct 19, 2020 3:04 am

Fri Jun 04, 2021 6:35 am

Well, thanks for the help.

So, I will not be able to use your library for my project, too bad.
I will keep a eye on the forum in case an update is coming.

Best regards.

jeremyc87
 
Posts: 3
Joined: Tue Jun 01, 2021 12:46 pm

Mon Jun 07, 2021 1:43 am

Okay, if there is any update, we will let you know.

Sincerely,
Brian
E-iceblue support team
User avatar

Brian.Li
 
Posts: 1271
Joined: Mon Oct 19, 2020 3:04 am

Return to Spire.PDF