Ureader.com  
Microsoft software help and Community
   home   |   control panel login   |   archive   |  
 
Exchange
2000.active.directory
2000.admin
2000.announcements
2000.app.conversion
2000.applications
2000.clients
2000.clustering
2000.connectivity
2000.development
2000.documentation
2000.general
2000.information.store
2000.interop
2000.kms
2000.misc
2000.protocols
2000.realtime.collabo.
2000.setup
2000.transport
2000.win2000
admin
application.conversion
applications
clients
clustering
connectivity
design
development
misc
mobility
setup
tools
  
 
date: Mon, 21 Jan 2008 14:54:45 -0500,    group: microsoft.public.exchange.development        back       


Accessing root folder using MAPI on Exchange 2007   
I am trying to open the root folder on Exchange 2007 using MAPI.  If I
use the following...

HrMAPIOpenFolderEx(lpMailbox, '\\', szStoreFolderPath, &lpRootFolder)

I can open the @PR_IPM_INBOX_ENTRYID but when I try and open
@PR_IPM_SUBTREE_ENTRYID it fails.  This works with Exchange 5.5 thru
2003.  Did they change the name of the root folder?  How do I access
the root folder for Exchange 2007 (on a client with MAPI support).  If
I look at it in OutlookSpy it still says IPM_SUBTREE for the display
name property on the root folder.

Thanks, David
date: Mon, 21 Jan 2008 14:54:45 -0500   author:   David

Re: Accessing root folder using MAPI on Exchange 2007   
David  wrote in 
news:2bt9p3p6bjgfr1rlbn796rp4me8s8ds4a3@4ax.com:
> I am trying to open the root folder on Exchange 2007 using MAPI.  If I
> use the following...
> 
> HrMAPIOpenFolderEx(lpMailbox, '\\', szStoreFolderPath, &lpRootFolder)

 HrMAPIOpenFolderEx is part of the EDK, which is bad:

http://blogs.msdn.com/jasonjoh/archive/2004/08/01/204585.aspx

 I'd guess there's a bug in there somewhere. You have a couple of choices:

 1. get the EDK source and trace through it to work out what's going on
 2. just write code yourself to read PR_IPM_SUBTREE_ENTRYID and openentry 
on that
 
 (or use the source code from MFCMAPI as a newer place to get sample code 
from -- that navigates down to top-of-info-store by opening the entryid 
above. If MFCMAPI doesn't work, then something strange is going on).
 
 -- dan
date: Mon, 21 Jan 2008 13:06:37 -0800   author:   Dan Mitchell

Re: Accessing root folder using MAPI on Exchange 2007   
Dan,

Thanks for the suggestion.  I started to play with the EDK source and
for the heck of it used the string "Top of Information Store" instead
of the @PR_IPM_SUBTREE_ENTRYID and it worked.  Not sure if it will
cause me grief in other languages.

On Mon, 21 Jan 2008 13:06:37 -0800, Dan Mitchell
 wrote:

>David  wrote in 
>news:2bt9p3p6bjgfr1rlbn796rp4me8s8ds4a3@4ax.com:
>> I am trying to open the root folder on Exchange 2007 using MAPI.  If I
>> use the following...
>> 
>> HrMAPIOpenFolderEx(lpMailbox, '\\', szStoreFolderPath, &lpRootFolder)
>
> HrMAPIOpenFolderEx is part of the EDK, which is bad:
>
>http://blogs.msdn.com/jasonjoh/archive/2004/08/01/204585.aspx
>
> I'd guess there's a bug in there somewhere. You have a couple of choices:
>
> 1. get the EDK source and trace through it to work out what's going on
> 2. just write code yourself to read PR_IPM_SUBTREE_ENTRYID and openentry 
>on that
> 
> (or use the source code from MFCMAPI as a newer place to get sample code 
>from -- that navigates down to top-of-info-store by opening the entryid 
>above. If MFCMAPI doesn't work, then something strange is going on).
> 
> -- dan
date: Tue, 22 Jan 2008 11:05:38 -0500   author:   David

Google
 
Web ureader.com


    COPYRIGHT 2007, YARDI TECHNOLOGY LIMITED, ALL RIGHT RESERVE  |   contact us