{"id":25594,"date":"2019-06-03T12:47:40","date_gmt":"2019-06-03T10:47:40","guid":{"rendered":"http:\/\/help.qualiware.it\/qw-help\/?p=25594"},"modified":"2019-06-03T12:51:10","modified_gmt":"2019-06-03T10:51:10","slug":"inserimento-di-un-campo-acrofield-in-un-file-pdf","status":"publish","type":"post","link":"https:\/\/help.qualiware.it\/qw-help\/inserimento-di-un-campo-acrofield-in-un-file-pdf\/","title":{"rendered":"Inserimento di un campo (acrofield) in un file PDF"},"content":{"rendered":"<p>&nbsp;<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"csharp\">' Il seguente frammento di codice mostra come si pu\u00f2 inserire un acrofield in un file PDF\r\n' vedere https:\/\/help.syncfusion.com\/file-formats\/pdf\/working-with-forms\r\n\r\n 'Load the existing PDF document.\r\n Dim filename As String=\"&lt;mettere qui il percorso del file da modificare&gt;\"\r\n\r\n Dim loadedDocument As New Syncfusion.Pdf.Parsing.PdfLoadedDocument(fileName)\r\n\r\n'Create the form if the form does not exist in the loaded document\r\nIf loadedDocument.Form Is Nothing Then\r\n   loadedDocument.CreateForm()\r\nEnd If\r\n\r\n'Load the page\r\nDim loadedPage As Syncfusion.Pdf.PdfLoadedPage = TryCast(loadedDocument.Pages(0), Syncfusion.Pdf.PdfLoadedPage)\r\n\r\n'Create a text box field and add the properties.\r\nDim textBoxField As New Syncfusion.Pdf.Interactive.PdfTextBoxField(loadedPage, \"Nome\")\r\ntextBoxField.Bounds = New RectangleF(0, 0, 100, 20) ' I primi due parametri sono le coordinate X e Y all'interno della pagina, che partono dall'angolo in basso a sinistra, il terzo \u00e8 la larghezza e il quarto \u00e8 l'altezza\r\ntextBoxField.ToolTip = \"Cognome e nome\"\r\n\r\n'Add the form field to the existing PDF document.\r\nloadedDocument.Form.Fields.Add(textBoxField)\r\n\r\n'Save the document.\r\nDim filename2=\"&lt;mettere qui il percorso del file modificato&amp;gt;\"\r\nloadedDocument.Save(filename2)\r\n\r\n'close the document\r\nloadedDocument.Close(True)\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>&nbsp; &#8216; Il seguente frammento di codice mostra come si pu\u00f2 inserire un acrofield in un file PDF &#8216; vedere https:\/\/help.syncfusion.com\/file-formats\/pdf\/working-with-forms &#8216;Load the existing PDF document. Dim filename As String=&#8221;&lt;mettere qui il percorso del file da modificare&gt;&#8221; Dim loadedDocument As New Syncfusion.Pdf.Parsing.PdfLoadedDocument(fileName) &#8216;Create the form if the form does not exist in the loaded document&hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"ngg_post_thumbnail":0,"footnotes":""},"categories":[65],"tags":[71],"acf":[],"_links":{"self":[{"href":"https:\/\/help.qualiware.it\/qw-help\/wp-json\/wp\/v2\/posts\/25594"}],"collection":[{"href":"https:\/\/help.qualiware.it\/qw-help\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/help.qualiware.it\/qw-help\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/help.qualiware.it\/qw-help\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/help.qualiware.it\/qw-help\/wp-json\/wp\/v2\/comments?post=25594"}],"version-history":[{"count":0,"href":"https:\/\/help.qualiware.it\/qw-help\/wp-json\/wp\/v2\/posts\/25594\/revisions"}],"wp:attachment":[{"href":"https:\/\/help.qualiware.it\/qw-help\/wp-json\/wp\/v2\/media?parent=25594"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/help.qualiware.it\/qw-help\/wp-json\/wp\/v2\/categories?post=25594"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/help.qualiware.it\/qw-help\/wp-json\/wp\/v2\/tags?post=25594"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}