What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » Scripting » [release] Who's online

[release] Who's online
Author: Message:
alexp2_ad
Scripting Contest Winner
****

Avatar
Who love the chocolate?

Posts: 691
Reputation: 26
37 / Male / –
Joined: May 2004
Status: Away
RE: [release] Who's online
Actually, use this... it uses minutes or seconds as appropriate, and rounds the number if it's decimal:

code:
var ThirtyMins = 1800000;
var SixtyMins = 3600000;
var FiveMins = 300000;
var TenMins = 600000;

// SET THE TIME YOU WANT TO USE HERE!
var mytime = ThirtyMins;

function OnEvent_Initialize(bMessengerStart){
    if(!bMessengerStart){ OnEvent_SigninReady(Messenger.MyEmail); }
}

function OnEvent_SigninReady(sEmail){
    var contacts = Messenger.MyContacts;
    var online = 0;
    var offline = 0;
    for(var e = new Enumerator(contacts); !e.atEnd(); e.moveNext()){
        item = e.item();
        if(item.Status != 1 && item.Status != 0){ online++; } else { offline++; }
    }
    MsgPlus.DisplayToastContact('Contact Counter', '[c=green]Online: '+online+'[/c]'+'[c=red]Offline: '+offline+'[/c]','Next count in '+TimeLength(mytime));
    MsgPlus.AddTimer('reload', mytime) //Repalce with SixtyMins if you want an hour
}

function OnEvent_Timer(sTimerId){
    if (sTimerId == 'reload'){
        OnEvent_SigninReady(Messenger.MyEmail); //Simply call the function so you dont duplicate code
    }
}

function TimeLength(time){
    if(time >= 60000){ return Math.round(time/60000)+" minutes"; }
    else{ return Math.round(time/1000)+" seconds"; }
}
08-28-2006 04:40 PM
Profile E-Mail PM Find Quote Report
« Next Oldest Return to Top Next Newest »

Messages In This Thread
[release] Who's online - by Jimbo on 08-27-2006 at 05:10 PM
RE: [release] Who's online - by Zeh on 08-27-2006 at 07:37 PM
RE: [release] Who's online - by alexp2_ad on 08-27-2006 at 08:42 PM
RE: [release] Who's online - by Zeh on 08-27-2006 at 08:46 PM
RE: RE: [release] Who's online - by alexp2_ad on 08-27-2006 at 08:51 PM
RE: [release] Who's online - by Zeh on 08-27-2006 at 08:56 PM
RE: RE: [release] Who's online - by alexp2_ad on 08-27-2006 at 09:00 PM
RE: [release] Who's online - by Zeh on 08-27-2006 at 09:02 PM
RE: RE: [release] Who's online - by alexp2_ad on 08-27-2006 at 09:04 PM
RE: RE: RE: [release] Who's online - by CookieRevised on 09-01-2006 at 09:36 AM
RE: RE: RE: RE: [release] Who's online - by alexp2_ad on 09-01-2006 at 10:05 AM
RE: RE: RE: RE: RE: [release] Who's online - by CookieRevised on 09-01-2006 at 05:30 PM
RE: RE: RE: RE: RE: RE: [release] Who's online - by alexp2_ad on 09-01-2006 at 05:38 PM
RE: [release] Who's online - by Zeh on 08-27-2006 at 09:10 PM
RE: [release] Who's online - by Spunky on 08-27-2006 at 11:17 PM
RE: [release] Who's online - by Zeh on 08-28-2006 at 04:05 PM
RE: [release] Who's online - by alexp2_ad on 08-28-2006 at 04:15 PM
RE: [release] Who's online - by Zeh on 08-28-2006 at 04:22 PM
RE: [release] Who's online - by alexp2_ad on 08-28-2006 at 04:40 PM
RE: [release] Who's online - by Zeh on 08-28-2006 at 04:51 PM
RE: RE: [release] Who's online - by alexp2_ad on 08-28-2006 at 04:58 PM
RE: [release] Who's online - by Zeh on 08-28-2006 at 05:02 PM
RE: RE: [release] Who's online - by alexp2_ad on 08-28-2006 at 05:05 PM
RE: [release] Who's online - by Zeh on 08-28-2006 at 05:07 PM
RE: [release] Who's online - by Jimbo on 08-29-2006 at 10:35 AM
RE: [release] Who's online - by Zeh on 08-29-2006 at 12:44 PM
RE: [release] Who's online - by Jimbo on 08-29-2006 at 06:41 PM
RE: [release] Who's online - by dylan! on 08-29-2006 at 07:11 PM
RE: [release] Who's online - by Jimbo on 09-01-2006 at 08:44 AM
RE: [release] Who's online - by CookieRevised on 09-01-2006 at 05:44 PM
RE: RE: [release] Who's online - by alexp2_ad on 09-01-2006 at 06:12 PM
RE: [release] Who's online - by Spunky on 09-01-2006 at 06:28 PM
RE: [release] Who's online - by Felu on 09-01-2006 at 06:34 PM
RE: [release] Who's online - by Jimbo on 09-02-2006 at 09:17 AM
RE: [release] Who's online - by Matti on 09-02-2006 at 09:21 AM
RE: [release] Who's online - by Felu on 09-02-2006 at 09:46 AM
RE: [release] Who's online - by CookieRevised on 09-02-2006 at 10:32 AM
RE: RE: [release] Who's online - by Felu on 09-02-2006 at 10:44 AM
RE: [release] Who's online - by Supersonicdarky on 09-02-2006 at 06:30 PM
RE: [release] Who's online - by Dave on 09-02-2006 at 09:15 PM
RE: [release] Who's online - by CookieRevised on 09-02-2006 at 10:15 PM
RE: [release] Who's online - by Dave on 09-03-2006 at 09:38 PM
RE: [release] Who's online - by CookieRevised on 09-04-2006 at 12:38 AM
RE: [release] Who's online - by Dave on 09-04-2006 at 07:23 AM
RE: [release] Who's online - by Jimbo on 09-07-2006 at 03:15 PM
RE: [release] Who's online - by xxhannahxx on 09-10-2006 at 11:55 AM
RE: [release] Who's online - by NanaFreak on 09-10-2006 at 11:59 AM
RE: [release] Who's online - by xxhannahxx on 09-10-2006 at 12:01 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