Error while filtering items in View object

Add-in Express™ Support Service
That's what is more important than anything else

Error while filtering items in View object
Error while filtering items in View object 
Anup Nair




Posts: 2
Joined: 2009-03-24
I am using VSTO for Outlook

I am programatically trying to set DASL filter on view object

TableView tableView = folder.CurrentView as TableView;
tableView.Filter = myFilter;
tableView.Save();
tableView.Apply();

This code snippet works file on an exchange mailbox, but fails on an IMAP (gmail) mailbox

Exception got
System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
at Microsoft.Office.Interop.Outlook._TableView.Save()

One observation is that I can manually go and set the filter on the current view

Any help would be appreciated

-anup
Posted 24 Mar, 2009 14:37:32 Top
Eugene Astafiev


Add-in Express team


Posts: 8540
Joined: 2007-07-25
Hello Anup,

Do you use Add-in Express?
.NET, Extended MAPI, Windows Phone & RT
Posted 25 Mar, 2009 04:39:45 Top
Anup Nair




Posts: 2
Joined: 2009-03-24
Yes I do
Posted 25 Mar, 2009 06:22:03 Top
Eugene Astafiev


Add-in Express team


Posts: 8540
Joined: 2007-07-25
Anup,

Could you reproduce the issue without Add-in Express? It looks like Add-in Express doesn't relate to the issue.
.NET, Extended MAPI, Windows Phone & RT
Posted 25 Mar, 2009 06:28:22 Top