What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » Scripting » Determing if message was first sent?

Determing if message was first sent?
Author: Message:
Zero
Junior Member
**

Avatar

Posts: 29
– / Male / Flag
Joined: Aug 2008
O.P. Determing if message was first sent?
I've been trying to figure out how I'd be able to determine if a received message was the first received message in the current chat window, but I can't seem to figure out a graceful way of doing this. Can anyone suggest/flesh out how I might go about it?

Zero

This post was edited on 08-13-2008 at 03:57 AM by Zero.
08-13-2008 03:56 AM
Profile E-Mail PM Web Find Quote Report
roflmao456
Skinning Contest Winner
****

Avatar

Posts: 955
Reputation: 24
30 / Male / Flag
Joined: Nov 2006
Status: Away
RE: Determing if message was first sent?
code:
var ChatWnds = new Array();
function OnEvent_ChatWndCreated(ChatWnd){
ChatWnds.push(ChatWnd);
}
function OnEvent_ChatWndReceiveMessage(ChatWnd, Origin, Message, MessageKind){
if(Origin !== Messenger.MyName){
for(i in ChatWnds){
if(ChatWnd === ChatWnds[i]){
// first message received..
}
}
}
}

could try that, haven't tested it since i'm currently skinning :P
[quote]
Ultimatess6
: What a noob mod
08-13-2008 04:17 AM
Profile PM Web Find Quote Report
segosa
Community's Choice
*****


Posts: 1407
Reputation: 92
Joined: Feb 2003
RE: RE: Determing if message was first sent?
quote:
Originally posted by roflmao456
code:
var ChatWnds = new Array();
function OnEvent_ChatWndCreated(ChatWnd){
ChatWnds.push(ChatWnd);
}
function OnEvent_ChatWndReceiveMessage(ChatWnd, Origin, Message, MessageKind){
if(Origin !== Messenger.MyName){
for(i in ChatWnds){
if(ChatWnd === ChatWnds[i]){
// first message received..
}
}
}
}

could try that, haven't tested it since i'm currently skinning :P

just need to make sure you set ChatWnds[i] to null in that if, otherwise the next message will be seen as the first too.
The previous sentence is false. The following sentence is true.
08-13-2008 09:48 AM
Profile PM Find Quote Report
Zero
Junior Member
**

Avatar

Posts: 29
– / Male / Flag
Joined: Aug 2008
O.P. RE: Determing if message was first sent?
mmmm... ok. i think i follow. not entirely sure so I'll need to experiment a bit once i'm back in front of my computer. thanks!
08-14-2008 07:54 PM
Profile E-Mail 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