A Microsoft Outlook email forum. Outlook Banter

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 » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Add-ins for Outlook
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Detect read messages count changed



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old February 14th 06, 05:06 PM posted to microsoft.public.outlook.program_addins
xhantt
external usenet poster
 
Posts: 1
Default Detect read messages count changed

Is there a way to detect when a message has been read from a folder.

I try this

Dim ol As Outlook.Application
Dim ns As Outlook.NameSpace
Dim WithEvents folders As Outlook.folders

Private Sub Command1_Click()
Set ol = New Outlook.Application
Set ns = ol.GetNamespace("MAPI")
Set folders = ns.GetDefaultFolder(olFolderInbox).folders
End Sub


Private Sub folders_FolderChange(ByVal Folder As Outlook.MAPIFolder)
unread = Folder.UnReadItemCount
End Sub

It work fine with messages inside subfolders of Inbox, but not with the
messages from Inbox.

Also there's a way to detect which change triggered the event?

 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
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 On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
New one for me. Messages change from READ to UNREAD JCollins Outlook - General Queries 8 September 15th 06 04:52 AM
In one profile, HTML forwarded messages read in plain text. Peter Sydney Outlook - General Queries 1 February 24th 06 11:22 PM
count contacts ems@drg Outlook - Using Contacts 1 February 23rd 06 06:54 PM
Junk E-mail folder stays in bold even after all messages marked as read Ric Outlook - General Queries 7 February 8th 06 01:53 AM
Messages view as read before I get a chance to look at them jp614 Outlook - General Queries 0 January 9th 06 10:50 PM


All times are GMT +1. The time now is 11:35 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2025 Outlook Banter.
The comments are property of their posters.