Solved

Javascript to create XML files

Posted on 2001-09-04
6
956 Views
Last Modified: 2008-02-01
Can anyone please tell me how to create XML files using Javascript?
If this possible?
0
Comment
Question by:desmondtsk
6 Comments
 
LVL 4

Expert Comment

by:chabaud
ID: 6453853
You can simply the XML DOM (with ie5).

Here is a good introduction:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/xmlsdk30/htm/xmconintroductiontothedom.asp

If you problem is to create a (xml) file on disk, you would have security constraints.
0
 

Accepted Solution

by:
devenkhatri earned 50 total points
ID: 6456441
to create xml file on the disk , first make a vbscript function which will use FileSystemObject object of vbscript
and then call that function in javascript
filesystemobject is the object of vbscript which will create the file on your disk , and in javascript u just traverse through the structure and write the nodes onto the file
0
 
LVL 2

Expert Comment

by:gvpathi_dev
ID: 6538407
Any way it gives a warning that shows running ActiveXobjects unsafe.  and another prob is VB Script not able to run in NS.  Is there is any other solution?...

I created a ActiveX DLL but with which the same problem persist..

A VC guy told that inherit ISafe.. to open that in scripting... but if we implement it we cannot save that object in local...(File system object deney...)  MS DOM itself come with a API called "Save" but it won't work in scripts...(From VB it works fine)




0
3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

 
LVL 4

Expert Comment

by:rdov
ID: 6560456
for Cross Platform XML Parsing in JavaScript try this:
http://xmljs.sourceforge.net/
0
 
LVL 2

Expert Comment

by:gvpathi_dev
ID: 6562734
rdov,
This is not the requirement.  He want the string to be stored into client machine?  Is it correct desmondtsk
?
0
 
LVL 1

Expert Comment

by:Moondancer
ID: 6617557
Finalized by:
Moondancer
Community Support Moderator @ Experts Exchange
0

Featured Post

3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

Question has a verified solution.

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

Suggested Solutions

The Problem How to write an Xquery that works like a SQL outer join, providing placeholders for absent data on the outer side?  I give a bit more background at the end. The situation expressed as relational data Let’s work through this.  I’ve …
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. 
Internet Business Fax to Email Made Easy - With  eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, f…
Many functions in Excel can make decisions. The most simple of these is the IF function: it returns a value depending on whether a condition you describe is true or false. Once you get the hang of using the IF function, you will find it easier to us…

867 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

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now