What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » Scripting » How to write to xml file?

How to write to xml file?
Author: Message:
y2kbug
New Member
*


Posts: 3
Joined: Jul 2006
O.P. RE: How to write to xml file?
quote:
Originally posted by rob_botch
To write to xml:

code:
var xml = new ActiveXObject("Microsoft.XMLDOM"); //Create xml object
xml.load(XMLPath); //XMLPath is the path of your XML file

var toAdd = xml.createElement("Element"); //Create an element called "Element"

toAdd.appendChild(xml.createTextNode("Text")); //Add the text "Text" to the element that you just created

xml.getElementsByTagName("Parent")[0].appendChild(toAddMessage); //Add the newly created element to the first instance of "Parent"

xml.save(XMLPath); //Save the XML file to the path specified


I hope that this helps,

Robert


I wanna say thankyou to you first. I have to find out more about this before I can tell whether it works or not.
07-31-2006 03:58 PM
Profile E-Mail PM Find Quote Report
« Next Oldest Return to Top Next Newest »

Messages In This Thread
How to write to xml file? - by y2kbug on 07-30-2006 at 04:33 PM
RE: How to write to xml file? - by Squelettor on 07-30-2006 at 09:05 PM
RE: How to write to xml file? - by y2kbug on 07-31-2006 at 07:00 AM
RE: How to write to xml file? - by CookieRevised on 07-31-2006 at 08:20 AM
RE: How to write to xml file? - by rob_botch on 07-31-2006 at 12:31 PM
RE: How to write to xml file? - by y2kbug on 07-31-2006 at 03:58 PM


Threaded Mode | Linear Mode
View a Printable Version
Send this Thread to a Friend
Subscribe | Add to Favorites
Rate This Thread:

Forum Jump:

Forum Rules:
You cannot post new threads
You cannot post replies
You cannot post attachments
You can edit your posts
HTML is Off
myCode is On
Smilies are On
[img] Code is On