View Single Post
  #2  
Old September 1st 06, 07:23 PM posted to microsoft.public.outlook.program_vba
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default How to know if can I access a folder ?

That's probably the best way. You can read the folder permissions but if you
don't have permissions on the folder attempting to read the permissions will
fire an error, so you're back to where you were before.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm


"Gianluigi Rubino" wrote in message
ups.com...
Hi all,
I'm making an outlook addin plugin in vb6.
I want to traverse the folders tree in a shared mailbox.
The problemi is that in some subfolders in this mailbox I don't have
access to them.

I found that I can enumerate the 'forbidden' subfolders in the .Folders
collections, but If I try to acces a proberty of that object I got an
'unkown error in the interface' sorry, but the message is in italian,
so I'm not sure if it's correctly translated it.

So I need to come up with a way if I can access the properties of that
MapiFolder object, i.e. I'd like to get some code like this:

If IsAuthorized(F) then
DoMyJobWithF
end if

Only way to get around this problem I could think of is some pseudocode
like this:
for ..... do
On Error goto SkipFolder
set F = Curr.Folders(i)
Name = F.Name
Whatever = f.whatever
SkipFolder:
Next

There are any (better) alternative to solve this problem ?
Thanky you very much


Ads