What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » Scripting » [help] read text file

[help] read text file
Author: Message:
phish
New Member
*


Posts: 9
Joined: Feb 2004
O.P. [help] read text file
well i wanted to read a text file so i use the following code
code:
function read() {
var fso = new ActiveXObject("Scripting.FileSystemObject");
var path = "C:\TEST.TXT";
var file = fso.GetFile(path);
fH = file.OpenAsTextStream(1, -2);
//...
//some other codes
//...
fH.Close();
}
but it doesn't work,
anyone helps to solve? thanks a lot

This post was edited on 08-12-2006 at 01:39 PM by phish.
An error occurred when reading the user's signature
08-12-2006 01:30 PM
Profile E-Mail PM Find Quote Report
matty
Scripting Guru
*****


Posts: 8336
Reputation: 109
39 / Male / Flag
Joined: Dec 2002
Status: Away
RE: [help] read text file
Your path has to have double \'s so
code:
var path = 'C:\\TEST.TXT';
08-12-2006 01:39 PM
Profile E-Mail PM Find Quote Report
phish
New Member
*


Posts: 9
Joined: Feb 2004
O.P. RE: [help] read text file
yeah~~ it works, thanks a lot.~
An error occurred when reading the user's signature
08-12-2006 01:41 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