Highlighted

how to add a data matrix barcode in designer forms

Avatar

Guest

03-04-2009

Hi im new to livecycle designer. I need to create a form with DataMatrix ECC200 barcode using livecycle designer. Could you please explain me how to set the value of the barcode using xml values. And could you please explain how to set the object details of the barcode.. Its very urgent..



Thanks in advance..

Replies

Highlighted

Steve_L_Walker

03-04-2009

If you are referring to the DataMatrix barcode symbology associated with the PaperFormsBarcode object, the formatting and content of the value encoded in a barcode depends upon the requirements on the 'back-office' side. In other words, a process consumes the data after the paper form is scanned and a barcode is decoded. You should map the barcode in the form to the data requirements in that process, whatever that process may be.<br /><br />The following custom script on a barcode calculate event will capture the relative form fields and encode the barcode as XML. The script replaces automatic scripting.<br /><br />form1.page1.subform1.barcode::calculate - (application/x-javascript, client)<br /><br />var str = '<?xml version="1.0"?>' <br />+ "<customer>"<br />+ "<name>" + form1.page1.subform1.name.rawValue + "</name>"<br />+ "<city>" + form1.page1.subform1.city.rawValue + "</city>"<br />+ "<state>" + form1.page1.subform1.state.rawValue + "</state>"<br />+ "<zipCode>" + form1.page1.subform1.zipCode.rawValue + "</zipCode>"<br />+ "</customer>";<br /> <br />this.rawValue = str;<br /><br />Steve
Highlighted

kruthis

06-04-2009

walker,

     I am having a xdp file for which i have data connection and a xml mapping. I need to encode some of the values from the xml and some fields that present in the xdp form. Im using collection to encode the field that present in the xdp by Automatic scripting. How i have to change the script to encode some of the values that is present in the xml?

Its a bit urgent..

Thanks in advance

Kruthis

Highlighted

leesutton

07-04-2009

If you are using a collection and the data you need to include is not listed in the collection object list then I would suggest creating hidden fields on your form that are bound to your datasource.  This would allow you to easily encode them into your barcode using the automated scripting.

Outside of that you will need to use custom code as demonstrated by Steve in the previous post.