Go Back   TechArena Community > Software > Software Development
Become a Member!
Forgot your username/password?
Register Tags Active Topics RSS Search Mark Forums Read

Sponsored Links



Parsing XML with Adobe Javascript

Software Development


Reply
 
Thread Tools Search this Thread
  #1  
Old 25-06-2010
Member
 
Join Date: Apr 2010
Posts: 56
Parsing XML with Adobe Javascript
  

I am working with the standard SQL QPAC to get data list from a database. As we are aware already that the standard SQL APAC is unable to access more than one rows at a time but I use the "FOR XML AUTO" in my SQL statement so that entire rows would be returned into the XML format.Currently, I only require to parse the XML and put the desired values into my drop-down list.

Does somebody have any script demo through which I can parse XML from within LiveCycle ??

Reply With Quote
  #2  
Old 25-06-2010
Member
 
Join Date: May 2008
Posts: 2,293
Re: Parsing XML with Adobe Javascript

Do you wanted to parse this in a script qpac ? If yes, then you can collect the XML in an xml process variable and then after attach the function as getProcessDataValue() from PATExecutionContext to access a Document object for the DOM.

You also need to go for a visit at the JavaDocs which came with the LiveCycle Workflow SDK. Within the Documentation/apiLiveCycle_ Workflow_SDK_API_Reference. In the script QPAC the PATExecutionContext is an implicit object retrieved within the patExecContext. In a customized QPAC, this is one of the parameter to the execute method.
Reply With Quote
  #3  
Old 25-06-2010
Member
 
Join Date: Apr 2010
Posts: 56
Re: Parsing XML with Adobe Javascript

I have tried to assign the following XML into an xml variable, but I got an error between these instead: 12Otis3

Do you know precisely, how to perhaps found the exact XML evaluation from a SELECT statement which will move into an XML variable? I have used "SELECT CLIENT_NAME as attribute from clients as list ORDER BY CLIENT_NAME FOR XML auto, elements" and I am working with a standard SQL QPAC to evaluate the XML results. Once, I receive the XML in perfect manner into the XML variable, I will try to use the getProcessDataValue() method.
Reply With Quote
  #4  
Old 25-06-2010
Member
 
Join Date: Feb 2008
Posts: 1,848
Re: Parsing XML with Adobe Javascript

Hi shiman, If you are running with the problems and trying to solve it in this method ,there are another option in this case and you also can go for that. you can download the SQLPlus QPAC, which will facilitate you to iterate over a result set and format the output according to the number required , including a easy and reliable comma separated list. Then after, you can then execute a simple script in the form to unzip the list to tag the values in the dropdown menu..
Reply With Quote
  #5  
Old 29-06-2010
Dr. V
 
Posts: n/a
Re: Parsing XML with Adobe Javascript

This may be just as easy to write a QPAC which fires the query and displayed the output a comma-delimited list as a string. You could then have the form take that string as a invisible section and parse this into the drop-down list in the same way that Work-flow facilitates the submission options drop-down list.
Reply With Quote
  #6  
Old 30-06-2010
Member
 
Join Date: Apr 2010
Posts: 56
Re: Parsing XML with Adobe Javascript

Thanks guys,

You all have given me a better suggestion and solutions which I can try someday. I actually mean that, but my intention with such specific work-flow is to work with only utilities which I get out of the box. I actually desired to know the dependent components well so that I get a complete understanding of what the suggested QPACs can and unable to do.

That method through which I get to know about the use of some loosely documented strategies such as getProcessDataValue(). Forgive my ignorance, can somebody please suggest me how to make a script that calls to this one method, if you have used this previously?
Reply With Quote
Reply

  TechArena Community > Software > Software Development
Tags: , , , , , , , , , , ,



Thread Tools Search this Thread
Search this Thread:

Advanced Search


Similar Threads for: "Parsing XML with Adobe Javascript"
Thread Thread Starter Forum Replies Last Post
Need another Javascript library for Adobe Edge jOjIi Windows Software 7 14-09-2011 11:23 PM
Adobe Acrobat - Javascript Console Bricklayer Software Development 6 28-07-2010 11:28 AM
Javascript Adobe problem cornto Windows Software 3 31-10-2009 03:03 PM
How to Disable Javascript in the Adobe PDF Reader ? SpearMan Tips & Tweaks 2 14-03-2009 07:38 PM
JavaScript with HTML Parsing! Samsher Software Development 4 02-02-2009 12:30 PM


All times are GMT +5.5. The time now is 03:00 PM.