A Windows XP help forum. PCbanter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » PCbanter forum » Microsoft Windows XP » Microsoft Messenger
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Starting in Invisible mode ?



 
 
Thread Tools Display Modes
  #1  
Old February 19th 04, 08:41 AM
Mangina
external usenet poster
 
Posts: n/a
Default Starting in Invisible mode ?

Hello all,
I was using the script below w/Windows Messenger and recently upgraded to
MSN Messenger 6.1.

The script loads the new Messenger just fine, however, it no longer makes me
invisible right away, I have to manually do this. Is there a problem with
the script ? Sometime I am missing ?
Many thanks.

' Constants to make this readable
CONST MSTATE_OFFLINE = 1
CONST MSTATE_ONLINE = 2
CONST MSTATE_INVISIBLE = 6, MSTATE_BUSY = 10
CONST MSTATE_BE_RIGHT_BACK = 14, MSTATE_IDLE = 18
CONST MSTATE_AWAY = 34, MSTATE_ON_THE_PHONE = 50
CONST MSTATE_OUT_TO_LUNCH = 66
counter = 0

set objMsgr = Wscript.CreateObject("Messenger.MsgrObject")
set objMsgrApp = Wscript.CreateObject("Messenger.MessengerApp")

'if we are already on line, QUIT
if objMsgr.LocalState MSTATE_OFFLINE then wscript.quit

'start the logon user interface; execution continues immediately
objMsgrApp.LaunchLogonUI

'Next we loop until we show as online
Do Until objMsgr.LocalState = MSTATE_ONLINE
WScript.Sleep 10
counter = counter + 1
' after 3 minutes we're not going anywhere so quit
if counter 18000 then objMsgrApp.Quit : wscript.quit
' ...so quit messenger and bail out of the script
Loop
'online now, so pause 20 ms and set to "Appear Offline"
wscript.sleep 20
objMsgr.LocalState = MSTATE_INVISIBLE
' pull up the messenger window while we're at it.
wscript.sleep 100
objMsgrApp.Visible = false



Ads
 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off






All times are GMT +1. The time now is 01:56 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 PCbanter.
The comments are property of their posters.