Tree based on XML DB files
Has someone ever tried to build a tree based on XML DB files?
Regards,
Learco
Hello,
Yeah I've done that before, I basically was getting XML exports and was running them against one of 3 XSLT's , users choice , and one was a tree. I'll dig up the code.
Or are you talking about building a tree based on all the files in XMLDB to navigate around them, I have a start on that I can give you as well, never finished it though.
Regards,
Carl
blog : http://carlback.blogspot.com/
apex examples : http://apex.oracle.com/pls/otn/f?p=11933:5
Similar Messages
-
Unparsing a DOM tree and write XML to file
Hi,
I have created a DOM tree from scratch and would like to unparse the DOM tree and write the XML to a file, but how do I do that?
Does anybody got code examples that do this?
All help are very appreciated!
/DanielThank you very much for the hint! Unfortunaly I still got problem to get it work though.
I made a little piece of test code to try it but during the execution of the "Transformer.transform(source,result)" method I gets an "org.w3c.dom.DOMException".
Does anybody see what that problem might be cause of by exmining the code below?
I also would like to know how to specify the location where I would like to print out the XML file.
Here is my little piece of test code:
try{
DocumentBuilderFactory docBuilderFactory = DocumentBuilderFadctory.newInstance();
DocumentBuilder docBuilder = docBuilderFactory.newDocumentBuilder();
Document doc = docBuilder.newDocument();
doc.appendChild(doc.createElement("topLevel"));
Element elm = doc.getDocumentElement();
elm = (Element)elm.appendChild(doc.createElement("PersonData"));
elm = (Element)elm.appendChild(doc.createElement("Name"));
elm.setAttribute("Firstname","D");
elm.setAttribute("Lastname", "D");
DOMResult result = new DOMResult(doc);
DOMSource source = new DOMSource(doc);
TransformerFactory transformerFactory = TansformerFactory.newInstance();
Transformer transformer = transformerFactory.newTransformer();
transformer.transform(source,result);
}catch(ParserConfigurationException e) {
}catch(IOException e) {
}catch(TransformerException te) { -
TREX Indexing issue. Form based publishing XML files.
In order to test my TREX indexing functionality, I have created a lot of test XML files (with form based publishing) containg test words.
What I experiments is that TREX only index the words that is presented on the 'Show' form of the xml document. The template created in the XML Forms Builder that is used to present the document. But thing is, that I only want to index the words from the XML source file, not from the 'Show' form template. Because on that i only have a static label with constant text.
How do I set TREX to index the source XML file and not the show form template representation of the file?Hi Flemming,
this works as designed. If you want index the whole XML data, you have to store your XMLForms items in a repository on which no "XMLFormsResourceFilter" is defined.
But if you do that, all the items are rendered as XML and not as HTML. So the SearchResult only gives you links pointing to XML files.
The only way to index more informations (from my point of view) is to store your additional information into ResourceProperties (you have to design your XMLFormsProject). These properties can be found by the search, if they are set to "indexable=yes".
Hope this helps
--Matthias -
How to calculate number of data records in a XML output file
Hi,
After generating a XML output file from Oracle Reports, I want to calculate number of records in the XML file. Is it possible? Specifically, I want to calculate number of records for a group variable ( organization_id, which I use for bursting).
Thanks for the help.Thanks BIPuser. It is useful for me.
I can use this xsl function within the template. However, I'm also looking to print this in the concurrent request log file. So, outside of rtf template, id there any PL/SQL based XML functions I can use to count the number of records.
Thanks. -
Okay, as a heads up I work for a financial institution and we are converting our legacy "jetforms" to pdf format. I have in my staff for the project, 2 code developers and myself- a form designer. We have currently spent 2 months in trial and error attempting to resolve this problem, please let us know anything you can have. All client-side (internal) machines are running Windows XP and Adobe Reader 7.0.7
The software we use as a financial institution allows our users to export a customer's data file onto their machine which is then renamed to include the member's account number and first and last name for our staff to determine which data file they need more accurately. In legacy jetforms, we have developed a program that pushes the data from the customers file that they select, into the jetform that they want to open and the matching fields in the data file fill in the fields of the jetform. Clean and simple.
Now, i have hit nothing but frustration when attempting to perform the same process with pdfs using a form designed in livecycle designer 7. First, i see no obvious command for opening a pdf and importing a data file using a command line, like pdfmerge or something of the sort in which an xml data file can be specified and a pdf can be specified. I saw something like it using an fdf format and attempted to do this but apparently reader cannot import the data into the pdf that was designed adobe livecycle 7. All i have been seeing is database connections and using javascript inside the form to populate fields based on these database connections, etc. etc. or doing a manual file>import data>etc. which we don't want to have our staff do. We do not have reader extensions enabled, simply because i cannot get an adobe representative to call me and discuss pricing nor see any estimated pricing chart around. I don't know if reader extensions are necessary for this or not but i'm becoming very very frustrated with it.
We don't want a complex server-side data connection binding with dynamic input. No, we just want it where our developers can say "if this data file is selected, and this pdf form is selected run this command" which would be a simple pdfmerge type solution. Is this possible or do i need to stay with jetforms until our software the billion dollar financial institution uses does form building inside its own application? I don't want to fight about who is better, what version to use, etc. I just want the straight up honest truth. If you need to know the pricing that the reader extensions would have to go by, assume there will be 500 client computers that will need to use it.From your post it sounds like you are Central Pro (a product for which I am by no means an expert), but you say you want to upgrade to a newer product from your "legacy" one. Is there a reason for this? Have your requirements change so that it no longer fits them? Central is still in the current Adobe roster and as far as I know there is no plans to get rid of it any time soon, so if it does everything you want I don't see why you would want to change.
There is no product in the LiveCycle suite that merges xml data into a form from the command line. LiveCycle (with the exception of Designer) is a suite of server products, so the closest you would come is LiveCycle Forms (merge the xml and create a fillable PDF) or LiveCycle Print (merge the xml and print the form).
Hope this helps somewhat.
Chris
Adobe Enterprise Developer Support -
Generated XML doc file contains comments from MFC source code
Hello, in my project I use the option /doc to generate XML doc file from my source codes but unfortunately in the output XML file there are mixed also comments from original MFC source codes, see the part of generated xml file:
Is there a solution to ignore these MFC cpp files?
Many thanks
Regards
Petr Stejskal
<?xml version="1.0"?>
<style xmlns="http://www.w3.org/1999/xhtml">@namespace html url(http://www.w3.org/1999/xhtml); :root { font:small Verdana; font-weight: bold; padding: 2em; padding- } * { display: block; padding- } html|style { display: none; } html|span, html|a
{ display: inline; padding: 0; font-weight: normal; text-decoration: none; } html|span.block { display: block; } *[html|hidden], span.block[html|hidden] { display: none; } .expand { display: block; } .expand:before { content: '+'; color: red; } .collapse
{ display: block; } .collapse:before { content: '-'; color: red; } </style><doc><assembly><assembly>
"Console" </assembly></assembly><members><members><member name="T:_RS"><member
name="T:_RS">Reed-Solomon codec control block</member></member><member name="M:MMask_makeMask(System.Int32,System.Byte*,System.Int32,QRecLevel)"><member
name="M:MMask_makeMask(System.Int32,System.Byte*,System.Int32,QRecLevel)">Mode indicator. See Table 2 in Appendix 1 of JIS X0510:2004, pp.107.</member></member><member
name="M:CMFCControlRenderer.IsScaled"><member
name="M:CMFCControlRenderer.IsScaled"><summary><summary>Tells whether this control
renderer works with scaled (resized) images.</summary></summary><returns><returns>Returns TRUE if this control
renderer works with resized (scaled) images.</returns></returns></member></member><member name="M:CMFCControlRenderer.SmoothResize(System.Double)"><member
name="M:CMFCControlRenderer.SmoothResize(System.Double)"><summary><summary>
Smoothly resizes images.</summary></summary><param name="dblScale" /><param
name="dblScale"> Scale ratio.</param><returns><returns>
TRUE if resize succeeds; otherwise FALSE.</returns></returns></member></member><member name="M:CDrawingManager.CreateBitmap_32(HBITMAP__*,System.UInt32!System.Runtime.CompilerServices.IsLong)"><member
name="M:CDrawingManager.CreateBitmap_32(HBITMAP__*,System.UInt32!System.Runtime.CompilerServices.IsLong)"><summary><summary>
Creates a 32 bit bitmap from the specified bitmap.</summary></summary><returns><returns> A handle to created
bitmap, or NULL, if creation fails.</returns></returns><param name="bitmap" /><param
name="bitmap"> A handle to the original bitmap.</param><param name="clrTransparent"
/><param
name="clrTransparent"> An RGB value specifying transparent color of the original bitmap.</param></member></member><member
name="M:CDrawingManager.CreateBitmap_32(CSize!System.Runtime.CompilerServices.IsConst*!System.Runtime.CompilerServices.IsImplicitlyDereferenced,System.Void**)"><member
name="M:CDrawingManager.CreateBitmap_32(CSize!System.Runtime.CompilerServices.IsConst*!System.Runtime.CompilerServices.IsImplicitlyDereferenced,System.Void**)"><summary><summary>
Creates an empty 32 bit bitmap.</summary></summary><returns><returns> A handle to created bitmap, or NULL,
if creation fails.</returns></returns><param name="size" /><param
name="size">Specifies bitmap size.</param><param name="pBits" /><param
name="pBits">When the function returns contains a pointer to bitmap bits.</param></member></member><member
name="M:CDrawingManager.DrawRotated(CRect,CDC*!System.Runtime.CompilerServices.IsImplicitlyDereferenced,System.Int32)"><member
name="M:CDrawingManager.DrawRotated(CRect,CDC*!System.Runtime.CompilerServices.IsImplicitlyDereferenced,System.Int32)"><summary><summary>Rotates
a source DC content inside the given rectangle by +/- 90 degrees</summary></summary><param name="rectDest" /><param
name="rectDest">Destination rectangle</param><param name="dcSrc" /><param
name="dcSrc">The source device content.</param><param name="bClockWise"
/><param
name="bClockWise">TRUE - rotate +90 degrees, FALSE - 90.</param></member></member><member
name="M:AfxRegDeleteKey(HKEY__*,System.Char!System.Runtime.CompilerServices.IsConst*,ATL.CAtlTransactionManager*)"><member
name="M:AfxRegDeleteKey(HKEY__*,System.Char!System.Runtime.CompilerServices.IsConst*,ATL.CAtlTransactionManager*)"><summary><summary>Deletes
the specified registry key.</summary></summary><returns><returns> If the function succeeds, the return
value is ERROR_SUCCESS. If the function fails, the return value is a nonzero error code defined in Winerror.h</returns></returns><param name="hKey" /><param
name="hKey">A handle to an open registry key.</param><param name="lpSubKey"
/><param
name="lpSubKey">The name of the key to be deleted.</param><param name="pTM" /><param
name="pTM">Pointer to CAtlTransactionManager object</param></member></member><member
name="M:AfxRegOpenKeyEx(HKEY__*,System.Char!System.Runtime.CompilerServices.IsConst*,System.UInt32!System.Runtime.CompilerServices.IsLong,System.UInt32!System.Runtime.CompilerServices.IsLong,HKEY__**,ATL.CAtlTransactionManager*)"><member
name="M:AfxRegOpenKeyEx(HKEY__*,System.Char!System.Runtime.CompilerServices.IsConst*,System.UInt32!System.Runtime.CompilerServices.IsLong,System.UInt32!System.Runtime.CompilerServices.IsLong,HKEY__**,ATL.CAtlTransactionManager*)"><summary><summary>Opens
the specified registry key.</summary></summary><returns><returns> If the function succeeds, the return
value is ERROR_SUCCESS. If the function fails, the return value is a nonzero error code defined in Winerror.h</returns></returns><param name="hKey" /><param
name="hKey">A handle to an open registry key.</param><param name="lpSubKey"
/><param
name="lpSubKey">The name of a key that this function opens or creates.</param><param name="ulOptions"
/><param
name="ulOptions">This parameter is reserved and must be zero.</param><param name="samDesired" /><param
name="samDesired">A mask that specifies the desired access rights to the key.</param><param
name="phkResult" /><param
name="phkResult">A pointer to a variable that receives a handle to the openedkey.</param><param
name="pTM" /><param
name="pTM">Pointer to CAtlTransactionManager object</param></member></member></members>Hi stejsky,
Thank you for posting in MSDN forum.
>>In my project I use the option /doc to generate XML doc file from my source codes but unfortunately in the output XML file there are mixed also comments from original MFC source codes.
Based on your issue, could you please tell me how you use the option /doc to generate XML doc file from your source codes?
If you use the option /doc to generate the XML doc file by right-click the your MFC project->Properties->Configuration Properties->C/C++->Output file->set the Generate XML document files as Yes(/doc) like the following screen shot.
(1)If yes, since we could not reproduce your issue in mu side, so if possible, I suggest you could share me your MFC project so that we will further help you support this issue.
You could upload your MFC project to the OneDrive and then copy link here.
(2)If no, please try the above way to generate XML doc file and then check if you still get same issue.
Best Regards,
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click
HERE to participate the survey. -
JAXP working with XML-XSL files - urgent help
I have the code below to transform xml file into html file using xsl file:
Transformer transformer = tFactory.newTransformer(new StreamSource("D:/Test/26120108026263560502.xsl"));
transformer.transform(new StreamSource("D:/Test/26120108028469387014574415483532664948806162003.xml"), new StreamResult(new FileOutputStream("D:/Test/Test.html")));
The code works fine with simple xml, xsl files, but it shows strange error messages when transforming more complex xsl file, please look at the errors below:
[Error] 26120108026263560502.xsl:3:80: Element type "xsl:stylesheet" must be declared.
[Error] 26120108026263560502.xsl:4:58: Element type "xsl:output" must be declared.
[Error] 26120108026263560502.xsl:6:75: Element type "xsl:include" must be declared.
[Error] 26120108026263560502.xsl:12:25: Element type "xsl:template" must be declared.
[Error] 26120108026263560502.xsl:14:7: Element type "html" must be declared.
[Error] 26120108026263560502.xsl:15:7: Element type "head" must be declared.
[Error] 26120108026263560502.xsl:16:8: Element type "title" must be declared.
[Error] 26120108026263560502.xsl:17:75: Element type "xsl:value-of" must be declared.
[Error] 26120108026263560502.xsl:19:74: Element type "meta" must be declared.
[Error] 26120108026263560502.xsl:20:8: Element type "style" must be declared.
[Error] 26120108026263560502.xsl:38:25: Element type "body" must be declared.
[Error] 26120108026263560502.xsl:39:48: Element type "xsl:call-template" must be declared.
[Error] 26120108026263560502.xsl:40:55: Element type "xsl:call-template" must be declared.
[Error] 26120108026263560502.xsl:41:49: Element type "xsl:call-template" must be declared.
[Error] 26120108026263560502.xsl:43:67: Element type "table" must be declared.
[Error] 26120108026263560502.xsl:44:7: Element type "tr" must be declared.
[Error] 26120108026263560502.xsl:45:21: Element type "td" must be declared.
[Error] 26120108026263560502.xsl:45:24: Element type "b" must be declared.
[Error] 26120108026263560502.xsl:45:51: Element type "br" must be declared.
[Error] 26120108026263560502.xsl:46:123: Element type "xsl:value-of" must be declared.
It look to me that JAXP can't recognize the tags. Everyone's help is appreciated.
NeilHere is the top part of it: ***********************
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE xsl:stylesheet [<!ENTITY nbsp " ">]>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="html" indent="no" encoding="UTF-8" />
<xsl:include href="http://connexion.vdr.com/ematrix/reports/xsllib.xsl" />
<xsl:template match="/">
<html>
<head>
<title>
<xsl:value-of select="//businessObject[objectType='CRA']/objectName"/>
</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"/>
<style>
TABLE
font-family: Arial Narrow, Tahoma, Verdana;
border: #000000 solid;
border-width: 2px 2px 0px;}
TABLE.BOTTOM
font-family: Arial Narrow, Tahoma, Verdana;
border: #000000 solid;
border-width: 2px 2px 2px;}
TD.DATA, TH.DATA
border: #cccccc solid;
border-width: 0px 1px 1px 0px;}
</style>
</head>
<body bgcolor="#FFFFFF">
<xsl:call-template name="ECRHeaderTable" />
<xsl:call-template name="ECRHeaderDetailsTable" />
<xsl:call-template name="ECRDetailsTable" />
Anh here is the top part of file xsllib.xsl in the xsl:include: ********
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE xsl:stylesheet [<!ENTITY nbsp " ">]>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<!--*******************************************************************
CalJulian - Calculate the Julian date for any date
Inputs: Year - Year
Month - Month
Day - Day
hour - hour (24 hour based, 0=midnight, 23=11pm)
min - minute
sec - second
History:
http://www.nr.com/julian.html
*********************************************************************-->
<xsl:template name="CalJulian">
<xsl:param name="Year"/>
<xsl:param name="Month" select="1"/>
<xsl:param name="Day" select="1"/>
<xsl:param name="Hour" select="0"/>
<xsl:param name="Min" select="0"/>
<xsl:param name="Sec" select="0"/>
<xsl:variable name="jy">
<xsl:choose>
<xsl:when test="($Year < 0) and ($Month > 2)">
<xsl:value-of select="$Year + 1"/>
</xsl:when>
<xsl:when test="($Year >= 0) and ($Month <= 2)">
<xsl:value-of select="$Year - 1"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="$Year"/>
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
The files work fine when I use msxsl.exe without any errors. I forgot to mention that dispite all the errors, JAXP still creates the html file but seeing the errors is not a good thing.
Neil -
How to select path from an XML data file?
I have an XML data file somewhat like the one below with up to five levels deep (variable). I want the user to be able to pick a path by navigating a tree (i.e. Canada/Alberta/Calgary) and have that path put into a data field. If they only navigate part way into the path (i.e. Mexico/Sonora) then that would go in the data field. I have some control of the structure of the XML as I am creating it from a CSV file.
Any examples or good advice that you can provide is greatly appreciated. I'm OK manipulating XML but am quite a newbie at PDF forms & Javascript.
<location>
<country name="Canada">
<prov-state name="British Columbia">
<city name="Victoria" />
<city name="Nanaimo" />
</prov-state>
<prov-state name="Alberta">
<city name="Calgary" />
<city name="Lethbridge" />
</prov-state>
</country>
<country name="Mexico">
<prov-state name="Sonora">
<city name="Guaymas" />
</prov-state>
</country>
</location>Not sure I follow ....are you going to give the user a visual representation of the XML and let them choose then you
will put the path into a field?
Paul -
Creating xml format file with double dagger ‡ as delimiter
Hi,
My source files are delimited with double dagger (‡) and I am using openrowset to load the files to SQL Server. When I am creating the format file by specifying the delimiter as ‡, the format file created has a different delimiter than the specified one.
The new delimiter appearing in xml format file is ç.
Any help?
TIA
Nitesh Rai- Please mark the post as answered if it answers your questionHow did you create format file?
Try this method and see if it works
http://visakhm.blogspot.com/2013/10/generate-format-files-based-on-table.html
Please Mark This As Answer if it helps to solve the issue Visakh ---------------------------- http://visakhm.blogspot.com/ https://www.facebook.com/VmBlogs -
How to create dynamic tree based on BAPI
Hi
I am able to create dynamic tree based on flat file structure example given in SDN . But how to create the tree from BAPI directly.Also when I will be clicking on any leaf node of the tree some data related to the node will be passed to another view.
Regards
AnandaWhat i'm trying to do is create an organizational structure.
Global>Region>Plant-->Corporation
The output from the RFC is a structure containing every possible combination for orgazational hierarchy. Basically a flat table with record for every possible combinaton of Region-Plant-Corporation. This data needs to be bound to a tree structure so that we can call BW queries based on that level. For example: Give me aged inventory for the SAP corporation within the plant Berlin that is located in the Europe region.
Now that you understand the business reason will the nodes that represent Region and Plant and corporation be non-singleton nodes or recursive? I was thinking a hierarchy of non-singleton nodes.
I can bind these nodes to the Region - Plant - Corporation elements returned from in the flat table structure. I will probably get duplicates as a specific Region will be listed multiple times for every possible combination of the data beneath it. I'm not so concerned about that right now as I want to make sure I understand how in Web Dynpro to bind the data to the tree.
Hopefully this makes some sense. Can you elaborate on how this may be constructed in context of the view?
Would i create a model node for region (0..n), model node for plant (0..n), and a model node for Corporation (0..n)?
Or does this sound totally incorrect?
julian
We have 3 regions over 50 plants and probably around 500 corporations. -
I though I found gold but it has nothing when I clicked on it.
Steve Muench's "Not Yet Documented Examples" [http://blogs.oracle.com/smuenchadf/resource/examples] > "Using ViewObject writeXML and JSTL XML Tag Library" suppose to provide the example. but I am getting File not found error. Seems the sample application doesn't exists any more.
Please point me to correct example for my following use case:
At Run-time:
1. My Application will ask user for database table name.
2. for provided database table name, my application should Generate XML Definition file for EO, Associations, VO and View Links inside Model Project (basically all definition file should be created which gets created when developer create these Business Components for database table through JDeveloper Studio).
3. Once done, application should also generate JSPX file using ADF page template in ViewController Project, with binding definition to it's corresponding newly generated VO Objects from step 2.
4. The page will be then, visible to user to use it (create/update/delete records)
First of all, is it possible to achieve above requirement ? Based on description of Steve Muench's "Using ViewObject writeXML and JSTL XML Tag Library", I think it is possible, but I don't have the sample application to refer.
I could have used dynamic view object concept to display the records with basic page layout. But I want users the ability to modify the create/records/delete the records with following requirements:
1. If require, Business Logic Developer can use Jdeveloper Studio to access new generated Business Components and modify it (like adding some validation rules)
2. If require, UI Developer can access newly generated JSPX file and change the layout.
Please let me know how much and how can I achieve it ?Shay,
Thank you for your reply. I will take a look at your links.
Use Case:
Application will have different BC for different IT Assets (like Monitor, Keyboard, Servers etc), which will basically hold records for all available Assets (like Display Resolution, screen size etc for all monitor in Monitor BC).
I want to give user; the ability to create, for e.g., the sub-class of Monitor to store more specific attribute-values in different table (which will be linked Parent BC). For e.g.: They may want to care about holding CRT and LCD Monitor records in separate new database table -- Application will ask user what all attributes/Columns they want to see for LCD which is specific to this type AND which is not present in already existing out-of-box Monitor BC/Table - e.g. - "Viewing Angle" Attribute).
With that said, I can write code to create database table on fly (having 1-to-1 foreign key reference to parent table) but writing ADF part seems difficult. I also wanted application to automatically generate new page for newly added VO BC. E.g.: LCD-Monitor.JSPX inheriting all attributes from monitor (parent VO) in the same structure as Monitor.JSPX file is having with extra LCD-specific Attributes in separate panel tab (which again UI developers can customized it).
Too much to expect huh !
I am going to start building the application so If not above way, any other suggestion to achieve the requirement ?
Edited by: Anandsagar Sah on Aug 29, 2011 9:23 PM -
Create .XML Project File from Scratch
Hi,
i am from germany, currently writing my bachelors degree creating an automated video editing solution based on final cut studio (yeeessss ... finally
I need to write complex final cut pro projects FROM SCRATCH in an EXTERNAL .XML editor using to greatly speed up the workflow. This means i am looking for any help regarding this topic, such as applescripts who can assist me in doing this.
(Example: Create an Final Cut (.xml) Project with applescript that has already included links to media on an external server, has music in it etc.)
I already have the "FinalCutPro_XML" reference and the "quickie_slate" Applescript which is a start. Any more tips where to look would be greatly appreciated.
Thanks in advance!
Best Regards,
Markus
MacBook Pro 17", Mac Mini Mac OS X (10.4.8)Marcus
i'd recommend you create an empty project file in FCP and export it to XML.
use the exported file as resource data, as it provides you with the basic XML project file container.
then you can just add the additional <parent> and <child> elements as required
also highly recommended would be the free XMLLib osax from Satimage, although it would be better if you learn how to do it with the built in libraries
for basic aplescript info, visit http://applescriptsourcebook.com/
cheers
Andy -
Script code sample for looping through the records from xml data file in formCalc script
Hi
I have a xml data file which contains a sequence of repeating applicant data like given below
US
II
CEO
Mr
111111111
0000000111
GuarantorA
111
IN
11111
WILLIAMS1
R3
KENNETH1
City1GU
PA
1934-03-14
[email protected]
GU
R
113 Lazlo LaneCA
Suite 3500CA
OaklandCA
TX
11345
AL
I want to assign a textfield with a value based on the value of coap_flag.
So i need to loop through all the record and check the value of coap_flag and then assign the textfield a value based on that.
I am new to Adobe livecycle...Please help me how it can be done.
I have developed something like this
foreach Item in ($record.applicant[*].coap_flag) do
test.value=Item
if(test.value=="MA")then
concat($record.applicant.first_name,$record.applicant.middle_name)endif
endforUsing the data you posted in the forum, I copied it a couple of times to give multiple records and used this code to extract the different values that you wanted. I had to wrap it in a <root> node that I called root (to make it valid XML). In my case I wrote the extracted values to a field, but in your case you can do whatever you want with them. Note that this was done in javascript:<br /><br />var currentElement;<br />var obj;<br /><br />//Get the nodes below the root node in the dataDom<br />obj = xfa.datasets.data.root.nodes;<br /><br />//Set an initial value for the textField<br />TextField1.rawValue = "The values of the coap_flag are: ";<br /><br />//Loop through the nodes in the obj set <br />for (i=0; i< obj.length ; i++){<br /> //set the currentElement to the 1st child node<br /> currentElement = obj.item(i);<br /> //Check to see if it is an applicant node<br /> if (currentElement.name == "applicant"){<br /> //It is an applican, now find the coap_flag node value and write it to the text field<br /> TextField1.rawValue += "\n" + xfa.resolveNode("xfa.datasets.data.root.applicant[" + i + "]").coap_flag.value;<br /> }<br />}
-
Loop through the records from xml data file in formCalc script
Hi
I have a xml data file which contains a sequence of repeating applicant data like given below
US
II
CEO
Mr
111111111
0000000111
GuarantorA
111
IN
11111
WILLIAMS1
R3
KENNETH1
City1GU
PA
1934-03-14
[email protected]
GU
R
113 Lazlo LaneCA
Suite 3500CA
OaklandCA
TX
11345
AL
I want to assign a textfield with a value based on the value of coap_flag.
So i need to loop through all the record and check the value of coap_flag and then assign the textfield a value based on that.
I am new to Adobe livecycle...Please help me how it can be done.
I have developed something like this
foreach Item in ($record.applicant[*].coap_flag) do
test.value=Item
if(test.value=="MA")then
concat($record.applicant.first_name,$record.applicant.middle_name)endif
endforUsing the data you posted in the forum, I copied it a couple of times to give multiple records and used this code to extract the different values that you wanted. I had to wrap it in a <root> node that I called root (to make it valid XML). In my case I wrote the extracted values to a field, but in your case you can do whatever you want with them. Note that this was done in javascript:<br /><br />var currentElement;<br />var obj;<br /><br />//Get the nodes below the root node in the dataDom<br />obj = xfa.datasets.data.root.nodes;<br /><br />//Set an initial value for the textField<br />TextField1.rawValue = "The values of the coap_flag are: ";<br /><br />//Loop through the nodes in the obj set <br />for (i=0; i< obj.length ; i++){<br /> //set the currentElement to the 1st child node<br /> currentElement = obj.item(i);<br /> //Check to see if it is an applicant node<br /> if (currentElement.name == "applicant"){<br /> //It is an applican, now find the coap_flag node value and write it to the text field<br /> TextField1.rawValue += "\n" + xfa.resolveNode("xfa.datasets.data.root.applicant[" + i + "]").coap_flag.value;<br /> }<br />}
-
Creating Multiple XML target file
HI Experts,
I would require some guidance from you. I have a situation whereby, I have to create multiple XML target file based on records.
The job in my hand is to extract the customer master from ECC and load it into XML files. But the catch is I need to create one XML file per customer. ie if my source has 500 customer then i have to create 500 XML and each XML file should contain all the information for that customer.
Can anyone guide me how to split the target XML in a single job. i.e. One XML per record of source data.Hi Dirk,
Please find the below screenshot of job
workflow
Initialization Script
While LOOP
Increment Script
data flow
Target XML
Please help me with this.
Maybe you are looking for
-
TV Tuner USB TV Tuner Analog Global Stick not detected on HP G42 360TX (help me)
sorry my bad english. i buy USB TV Tuner Analog Global Stick. see the product : http://sangattaonline.com/?vwdtl=ya&pid=47 i plug that tv tuner usb to my usb port on HP G42. My notebook not detect new hardware. There not notification on taskbar abo
-
BUG: Popup in page fragment; with many regions and popup binded to backing.
BUG: Popup in page fragment; with many regions and popup or parent binded to backing bean. JDEV11.1.2.1 Popup will not popup.(sometimes works if using RichPopup.Show() in backing bean Java code.) I have a bug (Popup will not popup)that only happens w
-
Contact list does not have iPhone listing
My iPhone 4S does not have an iPhone option in the Contact list (just lists 'mobile'), sometimes it will recognize someone else's text but not always, what can I do?
-
CILK language installation error
hi all; i'm using IMac with intel processor and i'm using Mac OS X 10.5.8 and i installed Cilk multithreading programming language ... but when i execute "make install" command after success full execution of ./configure, i get one error"error to exe
-
Revel on line and Photoshop Elements 12 do not match.
I have one active e-mail pjdcan2... and my revel on line shows 742 photos. I have more albums and photos in Elements 12 that are not uploaded to my account. I have logged out of both elements 12 and revel and then signed back in. This has not solv