473,320 Members | 1,856 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

substituting blank spaces with hyphen and generating a tree

This was our earlier design

<Product Inventory Info>
<Company>
<Make>Computer General</Make>
<Model>Wizbang 1900</Model>

It was later found that <Product Inventory Infohad spaces in
between. It was later decided that it has to be of the following
format

<Product-Inventory-Info nodeName="Product Inventory Info">
<Company nodeName="Company">
<Make nodeName="Make" nodeValue="Computer General" />

These tags are virtual tags created. I need to parse irt and generate
a dom tree based on attributes nodename ane nodevalue as the tags are
virtual tags which are created dynamically to avoid the empty spaces.
How should I do this?

Oct 30 '07 #1
2 2224
I need to display a tree structure on the applet with nodename and
nodevalue. As in regular XML the tag name becomes the nodename here
the tag is virtual so I was thinking to assign the value of nodename
attribute as the node name of the tree. The tree has to be displayed
on the GUI which is an applet. So I am generating a dom tree out of
xml and then transferring this data to the tree object that needs to
be displayed on the screen.
OK, so the XML part of it is straight XML, and the data transfer and
tree is straight applet coding. What's the question?
--
() ASCII Ribbon Campaign | Joe Kesselman
/\ Stamp out HTML e-mail! | System architexture and kinetic poetry
Oct 31 '07 #2
Could you tell me how I retrive the attributed from the node of a DOM
tree. Thanks in advance
Node.getAttributes().

Or, to retrieve a specific attribute by name, Element.getAttributeNS, or
Element.getAttributeNodeNS (the old non-NS versions of these are
effectively deprecated).

Any halfway-adequate DOM tutorial should show you how to do this.

--
() ASCII Ribbon Campaign | Joe Kesselman
/\ Stamp out HTML e-mail! | System architexture and kinetic poetry
Oct 31 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
by: Jean-Marc Molina | last post by:
Hello, I can't find a way to execute a Windows application, whose directory path contains blank spaces, from a PHP script. I also wonder if the problem happens under Linux and other OS. ...
6
by: Ruben | last post by:
Hello. I am trying to read a small text file using the readline statement. I can only read the first 2 records from the file. It stops at the blank lines or at lines with only spaces. I have a...
5
by: mark | last post by:
how to print, say 50 blank spaces, or say 20 blank spaces ? I wanted use such blank spaces that can be output in a program at predetermined places when printing with "cout".
3
by: larry | last post by:
Hi, I am a newbie to Internet programming. I have some questions about spacing in HTML control names and subsequently being able to access these input elements in JavaScript If you don't have...
1
by: Todd | last post by:
Hello, I'm am creating a CSV text import file for another application from my Access database. The other application requires a leading and following space surrounding a hyphen in the field...
5
by: Jonathan Ng | last post by:
Hi, I was wondering if there was a way to include the white spaces in a string. Currently, I am using: scanf("%s", &input); However, this doesn't include the 'space' character or any other...
3
by: Chris Sharman | last post by:
Are spaces allowed in names ? Eg <input name="my field" type="text" value="my data"> The html4 dtd seems to say this is cdata, which allows embedded single spaces, but say agents may trim...
2
by: spifster | last post by:
Hello all, I am building a collapsable tree using Javascript with DOM in IE. In order to make collapsed cells disappear I have been hiding the text. The cells collapse but still leave borders...
1
by: maryanncanor | last post by:
Hi everyone, My problem is whenever I export a report to a textfile. The output textfile have blank spaces. Here is my query: SELECT ( & '|' & & '|'...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.