Expand my Community achievements bar.

Guidelines for the Responsible Use of Generative AI in the Experience Cloud Community.

How to Define a Dynamic Barcode on a PDF Page?

Avatar

Level 1

I have a situation where we have a PDF form with multiple rows, (rows can be added as per the user's requirement), means user can click AddRow button and pdf will generate a new row to fill the data. There is no max limit of the rows, it vary and can be anywhere from row 1..10, 1..100, or 1..50 and so on.....

The first pice of the form is to create table/row with Add Row button has been completed. I have already added the AddRow button functionality into the form, but we also need to point the row's data to the barcode. Each data row should point to a single barcode 1 to 1 bases (One row one barcode). How to implement and design the barcode so that each row will be handled dynamically with one barcode? Or, if there is any better approach to handle this.

I would really appreciate if you could send any document, example or sample.

Thanks!

7 Replies

Avatar

Former Community Member

What you need to do is combine all of your data using a collection routine and then a pre-print routine that will spread the data across a dynamic number of barcodes for you. Tai Kedzierski actually has a great post on this topic on the cookbooks here: http://cookbooks.adobe.com/post_How_to_vary_the_number_of_barcodes_according_to_th-16499.html.

Avatar

Level 1

Thank you so much for your help!! I will check this out and let you know.

Thanks!

Avatar

Level 1

Hi Leesutton,

I have checked the barcode pdf file. In this example you have a single data field, and in my situation, there is a table & rows have defined for muliple rows entry. For example, In the figure below, I have 3 rows with 4 columns. How can I handle this? Please help to resolve the issue. Thank you.

-------------------------

|       |        |       |

-------------------------

|       |        |       |

-------------------------

|       |        |       |

-------------------------

Avatar

Level 1

What you basically need to do is move all of the xfa data into a single field (textarea, or just an internal node) and then do your barcode calculations on that single field. I'll see if I can't dig up another sample.

Avatar

Level 1

Hi apervez,

You need firstly to use a Paper Forms Barcode (PFB hereon). No other will do.

Secondly, you will probably want to have each PFB under the same parent node as the fields it is coding for

So that thirdly, you can access the row instance and its children and use the rawValues to populate the PFB in the calculate script event.

Note that PFB will come with custom scripting in the calculate event. Delete that script, and simply use this.rawValue = field1.rawValue + field2.rawValue + ... etc

Note that only the PFB can be updated whilst the PDF is open. Any other barcode needs to have its content set at design time, and will always be Read-Only or Protected.

Any specific example, please let us know.

Tai

Avatar

Level 1

Hi An_Tai,

Thank you so much for your solution.

The Adobe LiveCycle is totally new to me, and I was given an opportunity to modify one of oue existing form. I would really appreciate if you could provide a sample, or if you have steps/detail to implement this.

NOTE: JAvaScript is also new for me.

Thanks in advance!

Avatar

Employee

Consider the following scenario:

if you have defined a table and made a Cell in the table contain a TextField and it repeats, the SOM expression would look this

form1.Table1.Row1.TextField1[0] (Cell1 of Row1) as an example.

This instance of TextField[0] can be captured in the barcode Collection via the collection UI, but there is no way through the UI to get form1.Table1.Row1.TextField[1] (second instance) included in the barcode data.

I would check this blog entry out if you are interested in capturing values for repeating objects in a barcode, such as you might find in a dynamic table of a dynamic form:

http://blogs.adobe.com/formfeed/2010/02/paperforms_2d_barcodes_with_re.html