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 » Outlook and VBA
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Need help with MapiTable and EntryID/StoreID



 
 
Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1  
Old August 12th 07, 04:54 PM posted to microsoft.public.outlook.program_vba
Peter Marchert
external usenet poster
 
Posts: 116
Default Need help with MapiTable and EntryID/StoreID

Hello,

I did my first steps with MapiTable and it seems to be simple to
handle but this code does not work:

Sub MapiTableTest()

Dim objFolder As Outlook.MAPIFolder
Dim objTable
Dim Columns(2)
Dim Row

Const PR_SUBJECT As Long = &H37001E
Const PR_ENTRYID As Long = &HFFF0102
Const PR_STORE_ENTRYID As Long = &HFFB0102

Set objFolder = Outlook.ActiveExplorer.CurrentFolder

If objFolder.Items.Count 0 Then

Set objTable = CreateObject("Redemption.MAPITable")

objTable.Item = objFolder.Items

Columns(0) = PR_SUBJECT
Columns(1) = PR_ENTRYID
Columns(2) = PR_STORE_ENTRYID

objTable.Columns = Columns

objTable.GoToFirst

Do

Row = objTable.GetRow

If Not IsEmpty(Row) Then

Debug.Print Row(0)
Debug.Print Row(1)
Debug.Print Row(2)

End If

Loop Until IsEmpty(Row)

End If

End Sub

Row(1) and Row(2) always return a type mismatch error. I don`t know
why and need some help. Row(0) returns the subject of the item without
problems.

Beside this problem I want to ask if there is a simple way to compare
two mapi tables? For example to compare the email adress and the
subject of all items in two folders and get only the different items.

Thanks in advanced!

Peter

--
Infos, workshops & soft-
ware for your Outlook®:
www.outlook-stuff.com

 




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
SQL filters with MAPITABLE DENNIS BROWN Outlook and VBA 1 July 21st 07 09:50 PM
showing contact by StoreID / EntryID from favourite folders Johannes Franke Outlook - Using Contacts 6 June 8th 06 09:07 PM
showing contact by StoreID / EntryID from favourite folders Johannes Franke Outlook - Using Contacts 0 June 8th 06 03:22 PM
Scope of StoreID and EntryID Scott Outlook and VBA 4 January 20th 06 06:35 PM
Redemption MAPITable Dmitry Streblechenko Add-ins for Outlook 1 January 12th 06 04:09 AM


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