Can I bind a xml file dynamically to a form? say, bind to a different xml file after user select a value from a drop down list in the form?
how to do it? Thanks.Views
Replies
Total Likes
LiveCycle uses the XML as a sourcefile for generating the content, it is provided before generation meaning I seriously doubt your goal is achievable, yet I'm no expert in LiveCycle myself...
Views
Replies
Total Likes
Is the intention to re-populate the existing PDF form with a different XML instance?
Views
Replies
Total Likes
thanks for the reply.
what i trying to do it is to implement a form with multi language.
so, when a user select a language from a drop down list then labels and captions bind to a correct xml file.
or please advise the best way to implement a form with multi language.
thanks.
Views
Replies
Total Likes
I think it's best to create different XPD files for each language and add an XML tag <language>countryCode</language> to your XML dataset and XSD file. this way you could tell the workbench to use a different xpd file for generating the PDF file.
Anyway if you want to load an XML file from your local filesystem you should check out this URL: http://www.c-point.com/JavaScript/articles/file_access_with_JavaScript.htm it shows you how to read & write files using javascript.
The problem you'll be facing is editing the binding and reading + validating the given XML file. Especially validating the XML vs the XSD file used in the designer will probably cause a few errors, yet this is highly recommended in order to make sure you're not modifying your PDF with the wrong (or even malicious) data.
Security-wise i would not implement it your way but make a different XPD file for each language. In the LiveCycle Workbench you can select the correct XPD file based on the data you provide. Then it's just the user who needs to specify his/her language and your pdf is always build correctly. Yet I do not know if this is applicable to your situation and/or needs.
Views
Replies
Total Likes
I have attached a PDF that display captions based upon data binding. The PDF has two buttons - French and English. Based upon the selection you can import either 'captionFrench.xml' or 'captionEnglish.xml'.
If the attachments get queued, and they probably will, please send an email to stwalker.adobe@gmail.com and request the attachments.
Steve
Views
Replies
Total Likes
thanks MaFdOn, can you show me how to select a different xpd file from workbench?
is it possible to select the xpd file base on user's locale? how to do that?
thanks
Views
Replies
Total Likes
I'm really busy today, but you can make 2 workbench processes and each bind them to a different xpd file. It wouldn't surprise me if you could make it select a different depending on the xml data provided, but I have no time to verify at this very moment, I might later on the day.
Good luck
so, is there any way to get the locale in workbench and base on the information to choose the right process?
Views
Replies
Total Likes
Are you asking if a process could determine the locale of the Reader/Acrobat client and render a PDF for that locale?
Views
Replies
Total Likes
yes, but i am more interested in the livecycle workspace. when a user open a form from the workspace, can the process get the locale and display the form with the right language?
Views
Replies
Total Likes
Views
Likes
Replies