#150597 - 2005-10-25 10:57 PM
Outlook COM
|
Radimus
Moderator
   
Registered: 2000-01-06
Posts: 5187
Loc: Tampa, FL
|
I am running this:
$Outlook = CreateObject("Outlook.Application") $NS = $Outlook.GetNamespace("MAPI") $Fldr = $NS.GetDefaultFolder(6) $Unread = $Fldr.UnReadItemCount $Outlook = 0
But it isn't releasing it... It is still in processes.
Any idea how to release it?
|
Top
|
|
|
|
#150598 - 2005-10-25 11:03 PM
Re: Outlook COM
|
Chris S.
MM club member
   
Registered: 2002-03-18
Posts: 2368
Loc: Earth
|
Does...
Code:
$Outlook.Quit
...help?
|
Top
|
|
|
|
#150599 - 2005-10-25 11:11 PM
Re: Outlook COM
|
Radimus
Moderator
   
Registered: 2000-01-06
Posts: 5187
Loc: Tampa, FL
|
|
Top
|
|
|
|
#150600 - 2005-10-25 11:21 PM
Re: Outlook COM
|
Radimus
Moderator
   
Registered: 2000-01-06
Posts: 5187
Loc: Tampa, FL
|
Basically, I'm working on a mail check app to display the count of unread messages.
Code:
Global $up
Break On $System = CreateObject("Kixtart.System") $Root = $System.Form() $Right = $System.Screen.WorkingArea.Right $Bottom = $System.Screen.WorkingArea.Bottom
$OutTimer = $System.Timer() $OutTimer.Interval= 50 $OutTimer.OnTick = "IncTransparancy()"
;KD START
;************* OutMsg ************** $OutMsg = $System.Form($Root) $OutMsg.BackColor = 115,164,200 $OutMsg.ControlBox = "False" $OutMsg.FormBorderStyle = 0 $OutMsg.ShowInTaskBar = "False" $OutMsg.location = $right-275, $bottom-60 $OutMsg.Size = 275,60 $OutMsg.TopMost = "True" $OutMsg.opacity = 0 ;**************************************
;************* Label2 ************** $Label2 = $OutMsg.Controls.Label() $Label2.BackColor = $OutMsg.BackColor $Label2.FontSize = 20 $Label2.ForeColor = 255,255,255 $Label2.TextAlign = 32 $Label2.location = 0,0 $Label2.Size = $OutMsg.Size ;**************************************
;KD END
$Label2.text = "3 Unread Messages"
$OutMsg.Show $OutTimer.Start()
While $OutMsg.Visible $=Execute($OutMsg.DoEvents()) Loop Exit 1
Function IncTransparancy() if $OutMsg.opacity = 0 $up = 1 endif if $OutMsg.opacity = 100 sleep 3 $up = -1 endif $OutMsg.opacity = $OutMsg.opacity + $up if $OutMsg.opacity = 0 and $up = -1 $OutTimer.Stop() endif EndFunction
I have it hardcoded here, but you can see the COM code above to gather the details
BTW, you should hear the raging controversy this is causing in IT..
Quote:
Well, Conrad, if I decide to do some work without interruption, then that's what I should be able to do. Not be pestered to death by incessant email notifications when I do not want them, and I am not talking about myself but for other users who may want to work the way they want. If I want notifications , I will open Outlook, anything else is unnecessary and even burdensome and contra-productive.
Quote:
The entire "mail checker" component is not only unnecessary, but a bad idea.
Quote:
I think it is intrusive, and I think if employees should be REQUIRED to have their email open, then that is a supvisory detail, and not for us to decide. That's all. And by the way, what happened when people failed to call the number ??? Just because you get notificaction doesn't mean you read the email.
apparently I'm wasting my time...
Edited by Radimus (2005-10-25 11:22 PM)
|
Top
|
|
|
|
Moderator: Shawn, ShaneEP, Ruud van Velsen, Arend_, Jochen, Radimus, Glenn Barnas, Allen, Mart
|
0 registered
and 581 anonymous users online.
|
|
|