What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » Scripting » Need scripting help

Need scripting help
Author: Message:
Juffle
New Member
*


Posts: 2
Joined: Jan 2011
O.P. Need scripting help
Hi,

I'm trying to write a script that when I log on from my cell phone messenger client that my home PC messenger change my Display Picture to a mobile picture, then wait 10 mins of idle and change it again to another DP then wait 2 mins and change it back to my default one.

So far I've writen this but it dosent work at all... What I'm doing wrong ?

I would really appreciate some help as I'm not used in jscripting.

Thank you

Juffle

-----Code-----

var mobileCode = "(mp)";

function OnEvent_MyNameChange(NewName) {
    if (Messenger.MyName.lastIndexOf(mobileCode)) {
        MsgPlus.AddTimer(on,5000);
    }
}


function OnEvent_Timer(TimerId) {
    if (TimerId == "on") {
        Messenger.MyDisplayPicture = MsgPlus.ScriptFilesPath + "\\images\\mobile_on.gif";
        MsgPlus.AddTimer(off,600000);
    }
    else if (TimerId == "off") {
        Messenger.MyDisplayPicture = MsgPlus.ScriptFilesPath + "\\images\\mobile_off.gif";
        MsgPlus.AddTimer(default,120000);
    }
    else if (TimerId == default) {
        Messenger.MyDisplayPicture = MsgPlus.ScriptFilesPath + "\\images\\default.gif";
        Messenger.MyName = Messenger.MyName.replace(mobileCode,"");
    }
}


function OnEvent_ChatWndReceiveMessage(ChatWnd, Origin, Message, MessageKind) {
    if (Origin == Messenger.MyName) {
        if (Messenger.MyName.lastIndexOf(mobileCode)) {
            MsgPlus.CancelTimer(off);
            MsgPlus.CancelTimer(default);
            MsgPlus.AddTimer(on,5000);
        }
    }
}

---End Of Code-----
01-23-2011 09:30 PM
Profile E-Mail PM Find Quote Report
« Next Oldest Return to Top Next Newest »

Messages In This Thread
Need scripting help - by Juffle on 01-23-2011 at 09:30 PM
RE: Need scripting help - by CookieRevised on 01-24-2011 at 01:19 AM
RE: Need scripting help - by Juffle on 01-24-2011 at 01:33 AM
RE: Need scripting help - by CookieRevised on 01-24-2011 at 01:44 AM
RE: Need scripting help - by Spunky on 01-24-2011 at 12:31 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