{"id":4601,"date":"2017-02-16T22:50:37","date_gmt":"2017-02-16T22:50:37","guid":{"rendered":"https:\/\/alt2.minisoft.com\/support\/?p=4601"},"modified":"2017-02-16T22:50:37","modified_gmt":"2017-02-16T22:50:37","slug":"populating-a-pdf-form","status":"publish","type":"post","link":"https:\/\/minisoft.com\/support\/populating-a-pdf-form\/","title":{"rendered":"Populating a PDF Form"},"content":{"rendered":"<p>You can populate fields in a PDF document with data from various sources, including a database, shipping label, or XML.<\/p>\n<p><strong>Set up your variables<\/strong><\/p>\n<ol>\n<li>If your PDF file includes more than one page, create a variable and set its value to the system variable, Page Number.\u00a0Your PDF document can be any number of pages. This example uses the name\u00a0ThePage.<\/li>\n<li>Create a variable and set its value to the system variable, Full Data File Name. This example uses the name\u00a0FileName.<\/li>\n<li>Create other variables from your data source that you want to add to the PDF file.<\/li>\n<\/ol>\n<p><strong>Set up the PDF document<\/strong><\/p>\n<ol>\n<li>Create a Load Image rule and set the Use variable field to the variable you defined in Step 2 above, which contains the data file name. To create a Load Image rule, right click the form &gt; Add Rule &gt; Load Image:<img decoding=\"async\" loading=\"lazy\" class=\"size-medium wp-image-4602 aligncenter\" src=\"https:\/\/alt2.minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay1-300x135.jpg\" alt=\"\" width=\"300\" height=\"135\" srcset=\"https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay1-300x135.jpg 300w, https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay1-150x67.jpg 150w, https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay1-250x112.jpg 250w, https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay1-400x180.jpg 400w, https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay1.jpg 478w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/li>\n<li>In the Load Image Action window, set the Default resolution to 300.<img decoding=\"async\" loading=\"lazy\" class=\"size-medium wp-image-4608 aligncenter\" src=\"https:\/\/alt2.minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay4-300x138.jpg\" alt=\"\" width=\"300\" height=\"138\" srcset=\"https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay4-300x138.jpg 300w, https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay4-150x69.jpg 150w, https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay4-250x115.jpg 250w, https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay4-393x180.jpg 393w, https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay4.jpg 543w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/li>\n<li>Click PDF File using the Rule Variable.<\/li>\n<li>If your PDF document has more than one page, in the Page area, click Variable, and then select the variable you created in Step 1 of &#8220;Set up your variables&#8221; above.\u00a0<img decoding=\"async\" loading=\"lazy\" class=\"size-medium wp-image-4603 aligncenter\" src=\"https:\/\/alt2.minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay2-300x182.jpg\" alt=\"\" width=\"300\" height=\"182\" srcset=\"https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay2-300x182.jpg 300w, https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay2-150x91.jpg 150w, https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay2-250x152.jpg 250w, https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay2-296x180.jpg 296w, https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay2.jpg 449w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/li>\n<li>Click OK.<\/li>\n<\/ol>\n<p><strong>Place your variables<\/strong><\/p>\n<p>Each variable must be set with a Place Text rule. Complete these steps for each occurrence of each variable on each page. You can place the same variable multiple times on multiple pages.<\/p>\n<ol>\n<li>Right click the form &gt; Add Rule &gt; Place Text.<\/li>\n<li>Name the rule and select the variable to place.<\/li>\n<li>In the Place Text Action window, specify the position. You can drag the text to fine position it later.<\/li>\n<li>Click Change font and specify the font attributes to use. Click OK.<\/li>\n<li>If your PDF file contains multiple pages, set a condition so the variable does not show up on every page. Right click the rule &gt; Add AND condition &gt; Is equal to. Set the page number, and then click OK. The following example shows a condition to show the variable only on page 2:<img decoding=\"async\" loading=\"lazy\" class=\"size-medium wp-image-4605 aligncenter\" src=\"https:\/\/alt2.minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay3-300x206.jpg\" alt=\"\" width=\"300\" height=\"206\" srcset=\"https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay3-300x206.jpg 300w, https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay3-150x103.jpg 150w, https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay3-250x172.jpg 250w, https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay3-262x180.jpg 262w, https:\/\/minisoft.com\/support\/wp-content\/uploads\/2017\/02\/PDFOverlay3.jpg 399w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/li>\n<li>Verify that you see the variables in the correct positions on each page.<\/li>\n<li>Save your updated project.<\/li>\n<\/ol>\n","protected":false},"excerpt":{"rendered":"<p>You can populate fields in a PDF document with data from various sources, including a database, shipping label, or XML. Set up your variables If your PDF file includes more than one page, create a variable and set its value to the system variable, Page Number.\u00a0Your PDF document can be any number of pages. This [&hellip;]<\/p>\n","protected":false},"author":12,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3,105],"tags":[176,177],"_links":{"self":[{"href":"https:\/\/minisoft.com\/support\/wp-json\/wp\/v2\/posts\/4601"}],"collection":[{"href":"https:\/\/minisoft.com\/support\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/minisoft.com\/support\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/minisoft.com\/support\/wp-json\/wp\/v2\/users\/12"}],"replies":[{"embeddable":true,"href":"https:\/\/minisoft.com\/support\/wp-json\/wp\/v2\/comments?post=4601"}],"version-history":[{"count":5,"href":"https:\/\/minisoft.com\/support\/wp-json\/wp\/v2\/posts\/4601\/revisions"}],"predecessor-version":[{"id":4610,"href":"https:\/\/minisoft.com\/support\/wp-json\/wp\/v2\/posts\/4601\/revisions\/4610"}],"wp:attachment":[{"href":"https:\/\/minisoft.com\/support\/wp-json\/wp\/v2\/media?parent=4601"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/minisoft.com\/support\/wp-json\/wp\/v2\/categories?post=4601"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/minisoft.com\/support\/wp-json\/wp\/v2\/tags?post=4601"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}