Expand my Community achievements bar.

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

Connection to external xml file

Avatar

Level 1

How do I use an external xml file as a data source for my LiveCycle form?

I have an xml file on my server that is updated every few days by a script. My LiveCycle form is on the server and can be pushed to the client by the click of a button on a web page or similar. Is it possible to have the LiveCycle form refresh its data before being sent to the client, or every few days?

I was thinking that on the load of the form, a JavaScript function could check if the form is on the server, or check if the xml file is there, and if it is, update itself, else do nothing.

I would rather keep the xml file and the form seperate as other applications and scripts make use of the xml file.

Thanks.

1 Accepted Solution

Avatar

Correct answer by
Former Community Member

1) If the form is being used internally on the same network (ie: the xml file is always availabe via network to th form), the form can query local files, but this requires advanced scripting.

I haven't done it with shared network drives tho. - if you do, I use solution two

2)  Assuming you use LC Reader Extensions and the form is 'all over', not always on the originating network.

- Expose the XML file via a webservice (if it is not sensitive data)

- Get the form to query the webservice

3)But if you have LiveCycle installed with Forms.

Use the readXML component and then bind the XML with the Form.

View solution in original post

1 Reply

Avatar

Correct answer by
Former Community Member

1) If the form is being used internally on the same network (ie: the xml file is always availabe via network to th form), the form can query local files, but this requires advanced scripting.

I haven't done it with shared network drives tho. - if you do, I use solution two

2)  Assuming you use LC Reader Extensions and the form is 'all over', not always on the originating network.

- Expose the XML file via a webservice (if it is not sensitive data)

- Get the form to query the webservice

3)But if you have LiveCycle installed with Forms.

Use the readXML component and then bind the XML with the Form.

The following has evaluated to null or missing: ==> liqladmin("SELECT id, value FROM metrics WHERE id = 'net_accepted_solutions' and user.id = '${acceptedAnswer.author.id}'").data.items [in template "analytics-container" at line 83, column 41] ---- Tip: It's the step after the last dot that caused this error, not those before it. ---- Tip: If the failing expression is known to be legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)?? ---- ---- FTL stack trace ("~" means nesting-related): - Failed at: #assign answerAuthorNetSolutions = li... [in template "analytics-container" at line 83, column 5] ----