Outlook Banter

Outlook Banter (http://www.outlookbanter.com/)
-   Outlook and VBA (http://www.outlookbanter.com/outlook-vba/)
-   -   How do I modify Delete button to also mark item as read? (http://www.outlookbanter.com/outlook-vba/12496-how-do-i-modify-delete.html)

[email protected] April 23rd 06 07:29 PM

How do I modify Delete button to also mark item as read?
 
The default Delete button in Outlook 2003, seems to delete the item,
without marking it as read. Is there a way that I can modify it to
first mark the item as read, then delete the item? Would I need to use
VBA to accomplish this? If so, could anyone tell the code I should
write, as I am not very familiar with using VBA in outlook. Thanks.


Michael Bauer April 24th 06 06:14 AM

How do I modify Delete button to also mark item as read?
 
Am 23 Apr 2006 11:29:21 -0700 schrieb :

This sample marks all items as read which are being moved into the
DeletedItems folder.

Private WithEvents Items As Outlook.Items

Private Sub Application_Startup()
Set Items =
Application.Session.GetDefaultFolder(olFolderDelet edItems).Items
End Sub

Private Sub Items_ItemAdd(ByVal Item As Object)
Item.Unread=False
Item.Save
End Sub

--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
--
www.vbOffice.net --


The default Delete button in Outlook 2003, seems to delete the item,
without marking it as read. Is there a way that I can modify it to
first mark the item as read, then delete the item? Would I need to use
VBA to accomplish this? If so, could anyone tell the code I should
write, as I am not very familiar with using VBA in outlook. Thanks.



All times are GMT +1. The time now is 05:03 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-2006 OutlookBanter.com