Redemption MAPITable

  • Thread starter Dmitry Streblechenko
  • Start date
D

Dmitry Streblechenko

You need to pass a variant array, which is not the same as an array of
objects in C#.
I don't know if C# allows to do that in a different way, but on the low
level you will need to call the SafeArrayCreate Windows API function.

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

jim

I am trying to use MAPITable to speed up retrieval. I am using C#, but
it gives an exception: "IMAPITable::SetColumns() returned 0x80070057".
What object in C# do I need to pass to table.Columns ?

NameSpace ns = this.OutlookApp.GetNamespace("MAPI");
MAPIFolder folder = ns.GetDefaultFolder(OlDefaultFolders.olFolderContacts);
Redemption.MAPITable table = new Redemption.MAPITableClass();
table.Item = folder.Items;

object[] cols = new object[]{0x3001};
table.Columns = cols;
table.GoToFirst();
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top