What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » Scripting » Need a little bit of help. Time/Date

Need a little bit of help. Time/Date
Author: Message:
Br4yd3nP.Plus
Disabled Account


Posts: 20
Reputation: 1
Joined: Jun 2006
O.P. Need a little bit of help. Time/Date
var Message = "(Text Here) " + Messenger.MyName + "!";

Hello.

Is there somthing to replace MyName to show the time or date.

Brayden.
07-09-2006 04:13 PM
Profile E-Mail PM Find Quote Report
hmaster
Senior Member
****

Avatar

Posts: 716
Reputation: 24
33 / Male / Flag
Joined: Nov 2004
RE: Need a little bit of help. Time/Date
look at this piece of code, you should be able to figure it out :)

code:
var updatetime = 300;
var hours = null;
var minutes = null;
var seconds = null;
var textbtime = "(8) Me n U... ";
var textatime = ' :P';
var color1 = "#0A1C36";
var color2 = "#0080FF";

function OnEvent_Initialize(MessengerStart) {
Debug.Trace("----===[ Started Date n Time+ :) ]===----");
MsgPlus.AddTimer("time", updatetime);
}

function OnEvent_Signin(Email) {
the_time();
}

function the_time() {
var d = new Date();
if (d.getHours() < 10){
hours = "0" + d.getHours() + ":";
} else {
hours = d.getHours() + ":";
}

if (d.getMinutes() < 10){
minutes = "0" + d.getMinutes() + "/";
} else {
minutes = d.getMinutes() + "/";
}

if (d.getSeconds() < 10){
seconds = "0" + d.getSeconds();
} else {
seconds = d.getSeconds();
}
thetime = hours + minutes + seconds;
Debug.Trace("The time is: " + thetime);
Messenger.MyPersonalMessage = textbtime + thetime + textatime;
}

function OnEvent_Timer(sTimerId){
    if(sTimerId == "time"){
        the_time();
        MsgPlus.AddTimer("time", updatetime);
    }
}


Note: this changes only psm and shows the time. It also update per second, you may not want that.

This post was edited on 07-09-2006 at 04:26 PM by hmaster.
[Image: sig.png]
07-09-2006 04:19 PM
Profile PM Web 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