?
Solved

Linking dynamic HTML tables to XML with DSO

Posted on 2000-02-21
3
Medium Priority
?
319 Views
Last Modified: 2008-02-01
This has been bugging me all day...

I have the following embedded XML layout:

<XML ID="UsageReport">
   <Report>
      <Line>
         <User>person1</User>
         <Size>342</size>
      </Line>
      <Line>
         <User>person2</User>
         <Size>133</size>
      </Line>
   </Report>
</XML>

This works JUST FINE when I make a table like this:

<table datasrc="#UsageReport">
   <tr>
      <td><span datafld="User"></span></td>
      <td><span datafld="Size"></span></td>
   </tr>
</table>

The problem arises if I try to add a "header" section to the report, like this:

<XML ID="UsageReport">
   <ReportHeader>
      <ReportTitle>Usage Summary</ReportTitle>
   </ReportHeader>
   <Report>
   .
   .
   .
   </Report>
</XML>

In this layout, I can't seem to get to the data. I am guessing it has something to do with the data island structure, but I haven't read ANYTHING that says you can't have the layout like this. Unfortunately, the only examples I can find are either really simple, or obscenely complicated. Also, most of the examples were written for IE4 with the Java DSO stuff. I don't want to have to do a bunch of scripting just to lay out a simple little DHTML table.

I have tried messing with the DATAFLD attribute of the table, but I just can't seem to dig into the data if the Report element has any sibling-level elements (<ReportHeader> in the above example). Does anyone know of a simple (DHTML-only based) solution, or does the DSO linked data have to be linked by an element that has no sibling-level elements?

Thanks very much!

Donald
0
Comment
Question by:bytesmythe
  • 2
3 Comments
 

Author Comment

by:bytesmythe
ID: 2556360
Adjusted points to 100
0
 
LVL 1

Accepted Solution

by:
drom earned 400 total points
ID: 2590590
Hi, Donald.

you can't have sibling of root element in data island just like in xml-file. but you may workaround writing script for more complex island structure or adding extra <xml> for header/footer data:

--------------------------------------
<XML ID="usagereportheader">
<reportheader>
 <reporttitle>Usage Summary</reporttitle>
</reportheader>
</XML>

<XML ID="usagereport">
<reports>
<report>
 <user>user-1</user>
 <line>line-1</line>
</report>
<report>
 <user>user-2</user>
 <line>line-2</line>
</report>
</reports>
</XML>

<span datasrc="#usagereportheader" datafld=reporttitle></span>
<table datasrc="#usagereport">
<tr>
 <td><span datafld=user></span></td>
 <td><span datafld=line></span></td>
</tr>
</table>
--------------------------------------
Regards, Dmitry
0
 

Author Comment

by:bytesmythe
ID: 2596388
Thanks very much! I had read a number of documents about the data islands, but never saw anything that said they couldn't have siblings at the root level. I knew it wasn't working, but didn't know if that was the real reason or if I was just doing something wrong. :)
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The Client Need Led Us to RSS I recently had an investment company ask me how they might notify their constituents about their newsworthy publications.  Probably you would think "Facebook" or "Twitter" but this is an interesting client.  Their cons…
Many times as a report developer I've been asked to display normalized data such as three rows with values Jack, Joe, and Bob as a single comma-separated string such as 'Jack, Joe, Bob', and vice versa.  Here's how to do it. 
this video summaries big data hadoop online training demo (http://onlineitguru.com/big-data-hadoop-online-training-placement.html) , and covers basics in big data hadoop .
As many of you are aware about Scanpst.exe utility which is owned by Microsoft itself to repair inaccessible or damaged PST files, but the question is do you really think Scanpst.exe is capable to repair all sorts of PST related corruption issues?
Suggested Courses

850 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question