What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » Scripting » XML Saving and loading?

XML Saving and loading?
Author: Message:
TechedRonan
New Member
*

Avatar
Duja

Posts: 12
Joined: Jul 2006
O.P. XML Saving and loading?
How can i load and save data to an xml file?
07-21-2006 06:42 PM
Profile E-Mail PM Find Quote Report
-dt-
Scripting Contest Winner
*****

Avatar
;o

Posts: 1819
Reputation: 74
35 / Male / Flag
Joined: Mar 2004
RE: XML Saving and loading?
use the COM object Microsoft.XMLDOM
http://www.devguru.com/technologies/xmldom/quickref/obj_document.html

use the Load method and Save method
[Image: dt2.0v2.png]      Happy Birthday, WDZ
07-21-2006 06:47 PM
Profile PM Web Find Quote Report
TechedRonan
New Member
*

Avatar
Duja

Posts: 12
Joined: Jul 2006
O.P. RE: XML Saving and loading?
Uh, I'm not really understanding whats on that page... Not sure if i have to download something?

What I want to do is:
Set for example  the value to my nickname.
code:
<Information>
           <name>Value</name>
</Information>

07-21-2006 06:53 PM
Profile E-Mail PM Find Quote Report
-dt-
Scripting Contest Winner
*****

Avatar
;o

Posts: 1819
Reputation: 74
35 / Male / Flag
Joined: Mar 2004
RE: XML Saving and loading?
script
code:
var xml = new ActiveXObject("Microsoft.XMLDOM");
var file = MsgPlus.ScriptFilesPath + '\\settings.xml';
xml.load(file);
var node = xml.selectSingleNode("/Information/name");
node.text = "test";

xml.save(file);




settings.xml
code:
<Information>
           <name>Value</name>
</Information>


This post was edited on 07-21-2006 at 07:21 PM by -dt-.
[Image: dt2.0v2.png]      Happy Birthday, WDZ
07-21-2006 07:19 PM
Profile PM Web Find Quote Report
TechedRonan
New Member
*

Avatar
Duja

Posts: 12
Joined: Jul 2006
O.P. RE: XML Saving and loading?
Yeah thanks it works!
Now how can i get my own nickname from Initialize?
07-21-2006 07:32 PM
Profile E-Mail PM Find Quote Report
cloudhunter
Senior Member
****


Posts: 536
Reputation: 18
37 / – / –
Joined: Dec 2005
RE: XML Saving and loading?
Your own nickname is stored in "Messenger.MyName" :)

Cloudy
[Image: cloudy.jpg]
Sig by pirateok/marisaok/marisa ;)
quote:
Originally posted by Moulin Rouge
The greatest thing you'll ever learn, is just to love and be loved in return

6722 days, 6 hours, 1 minute, 24 seconds ago
07-21-2006 07:51 PM
Profile E-Mail PM Find Quote Report
TechedRonan
New Member
*

Avatar
Duja

Posts: 12
Joined: Jul 2006
O.P. RE: XML Saving and loading?
Yeh thanks

And finaly, how can I upload this on an ftp?
07-21-2006 08:30 PM
Profile E-Mail PM Find Quote Report
« Next Oldest Return to Top Next Newest »


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