How to Programatically Access specific MAPI folder

  • Thread starter Thread starter PS
  • Start date Start date
P

PS

All -

I am writing a small utility wherein I need to access/display all the
items under a specific MAPI Folder.

When viewing through the Outlook Spy - I can see all the details for
the folder but seriously need help accessing it programtically.

Tag num: 0x6656001E
Tag syn: 0x6656
Type: PT_STRING8

A little background on this is that - the name of the IMAPIFolder is
BlackBerryCalSyncState and this folder contains all the calender items
shown in the blackberry. Hence once i get a reference to this folder -
then I can iterate through the items and get the necesary details.

I am looking for any pointers/directions as soon as possible.

Thanks
 
And I forgot to add one more thing:

I would like to do this directly through Outlook Object Model but
also have Redemption dll purchased incase that is the only one which
would let me do it.

Sample code for any of them would be a big help.
 
Dmitry

I am able to understand that I will be able to access this folder info
through Redemption only.

The folder is located at the following location from the UI (writing
the step-by-step as done in Outlook Spy).

In Outlook explorer - Click on IMsgStore
Select Option Open Root Container
Under GetHierarchyTable - Double Click BlackBerryHanheldInfo
Under GetHierarchyTable - Double Click BlackBerryCalSyncState

This the folder I need to hook into.

Here are all the properties for that folder:

0x6656 PT_STRING8 <Exchange Home Server name here>
PR_ACCESS PT_LONG 63
PR_ACCESS_LEVEL PT_LONG 1
PR_ACL_DATA PT_BINARY cb:1, lpb: 00
PR_ASSOC_CONTENT_COUNT PT_LONG 0
PR_ATTR_HIDDEN PT_BOOLEAN false
PR_ATTR_READONLY PT_BOOLEAN false
PR_ATTR_SYSTEM PT_BOOLEAN false
PR_CHANGE_KEY PT_BINARY cb:22, lpb: C8 6D B9 DE C3 B1 91 4F 8D B1 5B
7D 42 BD A5 E6 00 00 13 B4 34 08
PR_COMMENT PT_STRING8
PR_CONTENT_COUNT PT_LONG 38
PR_CONTENT_UNREAD PT_LONG 0
PR_CREATION_TIME PT_SYSTIME 9:45 PM, 2/14/2008
PR_CREATOR_SID PT_BINARY cb:28, lpb: 01 05 00 00 00 00 00 05 15 00 00
00 CD 37 78 00 5B 1A E9 73 11 61 1B 45 F9 12 00 00
PR_DELETED_ASSOC_MESSAGE_SIZE_EXTENDED PT_I8 0
PR_DELETED_ASSOC_MSG_COUNT PT_LONG 0
PR_DELETED_COUNT_TOTAL PT_LONG 1
PR_DELETED_FOLDER_COUNT PT_LONG 0
PR_DELETED_MESSAGE_SIZE_EXTENDED PT_I8 134
PR_DELETED_MSG_COUNT PT_LONG 1
PR_DELETED_NORMAL_MESSAGE_SIZE_EXTENDED PT_I8 134
PR_DESIGN_IN_PROGRESS PT_BOOLEAN false
PR_DISPLAY_NAME PT_STRING8 BlackBerryCalSyncState
PR_DISPLAY_TYPE PT_LONG 16777216
PR_ENTRYID PT_BINARY cb:46, lpb: 00 00 00 00 9D B4 94 29 41 21 B0 47
95 B4 EC 91 C9 F0 E6 46 01 00 C8 6D B9 DE C3 B1 91 4F 8D B1 5B 7D 42
BD A5 E6 00 00 13 B4 14 AF 00 00
PR_EXTENDED_ACL_DATA PT_BINARY cb:16, lpb: 00 00 00 00 01 00 00 00 04
00 00 00 00 00 00 00
PR_FOLDER_CHILD_COUNT PT_LONG 0
PR_FOLDER_TYPE PT_LONG 1
PR_HAS_RULES PT_BOOLEAN false
PR_ICS_CHANGE_KEY PT_BINARY cb:44, lpb: C8 6D B9 DE C3 B1 91 4F 8D B1
5B 7D 42 BD A5 E6 00 00 13 B4 2F 2D C8 6D B9 DE C3 B1 91 4F 8D B1 5B
7D 42 BD A5 E6 00 00 13 B4 34 09
PR_INTERNET_ARTICLE_NUMBER PT_LONG 1332753
PR_LAST_MODIFICATION_TIME PT_SYSTIME 9:45 PM, 2/14/2008
PR_LAST_MODIFIER_SID PT_BINARY cb:28, lpb: 01 05 00 00 00 00 00 05 15
00 00 00 CD 37 78 00 5B 1A E9 73 11 61 1B 45 F9 12 00 00
PR_LOCAL_COMMIT_TIME PT_SYSTIME 9:45 PM, 2/14/2008
PR_LOCAL_COMMIT_TIME_MAX PT_SYSTIME 5:17 AM, 2/17/2008
PR_MAPPING_SIGNATURE PT_BINARY cb:16, lpb: C8 6D B9 DE C3 B1 91 4F 8D
B1 5B 7D 42 BD A5 E6
PR_MDB_PROVIDER PT_BINARY cb:16, lpb: 54 94 A1 C0 29 7F 10 1B A5 87 08
00 2B 2A 25 17
PR_MESSAGE_SIZE PT_LONG 5092
PR_NTSDModificationTime PT_SYSTIME 9:45 PM, 2/14/2008
PR_NT_SECURITY_DESCRIPTOR PT_BINARY cb:132, lpb: 08 00 03 00 00 00 00
00 01 00 04 8C 44 00 00 00 60 00 00 00 00 00 00 00 14 00 00 00 02 00
30 00 02 00 00 00 01 19 14 00 BF 0F 1F 00 01 01 00 00 00 00 00 05 07
00 00 00 01 12 14 00 BF C9 1F 00 01 01 00 00 00 00 00 05 07 00 00 00
01 05 00 00 00 00 00 05 15 00 00 00 CD 37 78 00 5B 1A E9 73 11 61 1B
45 F9 12 00 00 01 05 00 00 00 00 00 05 15 00 00 00 CD 37 78 00 5B 1A
E9 73 11 61 1B 45 01 02 00 00
PR_OBJECT_TYPE PT_LONG 3
PR_OFFLINE_FLAGS PT_LONG 0
PR_PARENT_ENTRYID PT_BINARY cb:46, lpb: 00 00 00 00 9D B4 94 29 41 21
B0 47 95 B4 EC 91 C9 F0 E6 46 01 00 C8 6D B9 DE C3 B1 91 4F 8D B1 5B
7D 42 BD A5 E6 00 00 13 B4 14 A6 00 00
PR_PARENT_SOURCE_KEY PT_BINARY cb:22, lpb: C8 6D B9 DE C3 B1 91 4F 8D
B1 5B 7D 42 BD A5 E6 00 00 13 B4 14 A6
PR_PREDECESSOR_CHANGE_LIST PT_BINARY cb:23, lpb: 16 C8 6D B9 DE C3 B1
91 4F 8D B1 5B 7D 42 BD A5 E6 00 00 13 B4 34 08
PR_RECORD_KEY PT_BINARY cb:46, lpb: 00 00 00 00 9D B4 94 29 41 21 B0
47 95 B4 EC 91 C9 F0 E6 46 01 00 C8 6D B9 DE C3 B1 91 4F 8D B1 5B 7D
42 BD A5 E6 00 00 13 B4 14 AF 00 00
PR_REPLICA_SERVER PT_STRING8 GSMBNOP10ES
PR_REPLICA_VERSION PT_I8 1688871836647426
PR_RESOLVE_METHOD PT_LONG 0
PR_RIGHTS (or PR_PROFILE_ABP_ALLOW_RECONNECT) PT_LONG 2043
PR_RULES_DATA PT_BINARY cb:9, lpb: 02 00 00 00 00 E4 04 00 00
PR_SEARCH_KEY PT_BINARY cb:46, lpb: 00 00 00 00 9D B4 94 29 41 21 B0
47 95 B4 EC 91 C9 F0 E6 46 01 00 C8 6D B9 DE C3 B1 91 4F 8D B1 5B 7D
42 BD A5 E6 00 00 13 B4 14 AF 00 00
PR_SECURE_ORIGINATION PT_BOOLEAN false
PR_SOURCE_KEY PT_BINARY cb:22, lpb: C8 6D B9 DE C3 B1 91 4F 8D B1 5B
7D 42 BD A5 E6 00 00 13 B4 14 AF
PR_STORE_ENTRYID PT_BINARY cb:306, lpb: 00 00 00 00 38 A1 BB 10 05 E5
10 1A A1 BB 08 00 2B 2A 56 C2 00 00 45 4D 53 4D 44 42 2E 44 4C 4C 00
00 00 00 00 00 00 00 1B 55 FA 20 AA 66 11 CD 9B C8 00 AA 00 2F C4 5A
0C 00 00 00 47 53 4D 42 4E 4F 50 31 30 45 53 00 2F 6F 3D 47 6F 6C 64
6D 61 6E 2C 20 53 61 63 68 73 20 26 20 43 6F 2E 2F 6F 75 3D 57 6F 72
6C 64 77 69 64 65 2F 63 6E 3D 52 65 63 69 70 69 65 6E 74 73 2F 63 6E
3D 50 72 61 74 69 6B 2E 53 68 61 68 00 D8 35 21 F3 A8 00 00 00 01 00
00 00 14 00 00 00 64 00 00 00 2F 6F 3D 47 6F 6C 64 6D 61 6E 2C 20 53
61 63 68 73 20 26 20 43 6F 2E 2F 6F 75 3D 57 6F 72 6C 64 77 69 64 65
2F 63 6E 3D 43 6F 6E 66 69 67 75 72 61 74 69 6F 6E 2F 63 6E 3D 53 65
72 76 65 72 73 2F 63 6E 3D 47 53 4D 42 4E 4F 50 31 30 45 53 00 67 00
73 00 6D 00 62 00 6E 00 6F 00 70 00 31 00 30 00 65 00 73 00 2E 00 66
00 69 00 72 00 6D 00 77 00 69 00 64 00 65 00 2E 00 63 00 6F 00 72 00
70 00 2E 00 67 00 73 00 2E 00 63 00 6F 00 6D 00 00 00 00 00
PR_STORE_RECORD_KEY PT_BINARY cb:16, lpb: 9D B4 94 29 41 21 B0 47 95
B4 EC 91 C9 F0 E6 46
PR_STORE_SUPPORT_MASK PT_LONG 344061
PR_SUBFOLDERS PT_BOOLEAN false
PR_URL_NAME PT_STRING8 /NON_IPM_SUBTREE/BlackBerryHandheldInfo/
BlackBerryCalSyncState
PR_VersioningFlags PT_I2 MAPI_E_NOT_FOUND

Thanks
 
Assuming it is in the default store, try the following:

set Folder =
Session.Stores.DefaultStore.RootFolder.Folders.Item("BlackBerryHanheldInfo").Folders.Item("BlackBerryCalSyncState")

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
 
Back
Top