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

Select/Unselect items in ActiveExplorer by code?



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old October 13th 09, 06:11 AM posted to microsoft.public.outlook.program_addins
Heinz-Josef Bomanns
external usenet poster
 
Posts: 10
Default Select/Unselect items in ActiveExplorer by code?

Good morning,

is there any way to select or unselect items in ActiveExplorer by
code? For e.g. there are five mails selected by the user, i process
each mail in my add in through a loop like this:

for each Item in ActiveExplorer.Selection
'Do something with the mail
if SomeCondition = True then
Item.Selected = False 'Is something like this possible?
'or perhaps Item.Unselect?
end if
next Item

After the loop is done there should remain for e.g. two mails
selected. Second example:

for each Item in ActiveExplorer.CurrentFolder
if SomeCondition = True then
Item.Selected = True 'Select the mail
'or perhaps Item.Select?
end if
next Item

This should select mails in ActiveExplorer based on criterias checked
for each mail. Thanks for any hints or suggestions...


--

So long...
...Bomi

!!! In case you want to reply via email please use Reply-To address and remove underscores (_) !!!

  #2  
Old October 13th 09, 03:47 PM posted to microsoft.public.outlook.program_addins
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default Select/Unselect items in ActiveExplorer by code?

The ability to do that was added to the object model in Outlook 2010. In
earlier versions of Outlook there's no way to do that.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.
http://www.slovaktech.com/products.htm


"Heinz-Josef Bomanns" wrote in message
...
Good morning,

is there any way to select or unselect items in ActiveExplorer by
code? For e.g. there are five mails selected by the user, i process
each mail in my add in through a loop like this:

for each Item in ActiveExplorer.Selection
'Do something with the mail
if SomeCondition = True then
Item.Selected = False 'Is something like this possible?
'or perhaps Item.Unselect?
end if
next Item

After the loop is done there should remain for e.g. two mails
selected. Second example:

for each Item in ActiveExplorer.CurrentFolder
if SomeCondition = True then
Item.Selected = True 'Select the mail
'or perhaps Item.Select?
end if
next Item

This should select mails in ActiveExplorer based on criterias checked
for each mail. Thanks for any hints or suggestions...


--

So long...
...Bomi

!!! In case you want to reply via email please use Reply-To address and
remove underscores (_) !!!


  #3  
Old October 16th 09, 10:43 AM posted to microsoft.public.outlook.program_addins
Heinz-Josef Bomanns
external usenet poster
 
Posts: 10
Default Select/Unselect items in ActiveExplorer by code?

Hallo Ken,

The ability to do that was added to the object model in Outlook 2010. In
earlier versions of Outlook there's no way to do that.


Thanks, was afraid of that


--

So long...
...Bomi

!!! In case you want to reply via email please use Reply-To address and remove underscores (_) !!!

 




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
Select a folder in Outlook (in code) Koen Verwimp Add-ins for Outlook 2 April 1st 09 04:14 PM
Outlook 2002 Custom Form only runs code if you select "run this fo Richard Korinek Outlook - Using Forms 2 February 6th 09 08:10 PM
There is a lag when I select menu items or perform operations? HR Dude Outlook - Installation 0 December 31st 06 02:59 AM
Select all items in outbox Joel Outlook and VBA 1 November 27th 06 07:09 AM
Find and select mail in ActiveExplorer Gvaram Outlook and VBA 2 October 1st 06 08:19 PM


All times are GMT +1. The time now is 10:27 PM.


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.