<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>(Less Than) Portable Search Folders</title><link>http://blogs.msdn.com/stephen_griffin/archive/2009/05/21/less-than-portable-search-folders.aspx</link><description>Let’s have fun with the object model and search folders: Outlook running a profile in online mode. Create this macro: Sub TestAdvancedSearchComplete() &amp;#160;&amp;#160;&amp;#160; Dim sch As Outlook.Search &amp;#160;&amp;#160;&amp;#160; set sch = Application.AdvancedSearch(&amp;quot;Inbox&amp;quot;,</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>re: (Less Than) Portable Search Folders</title><link>http://blogs.msdn.com/stephen_griffin/archive/2009/05/21/less-than-portable-search-folders.aspx#9634430</link><pubDate>Fri, 22 May 2009 01:37:10 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9634430</guid><dc:creator>Dmitry Streblechenko</dc:creator><description>&lt;p&gt;So is there a chance of having the SFST_FILTERSTREAM format documented?&lt;/p&gt;
&lt;p&gt;The very real problem I have is that firstly I cannot re-created a search folder with the search definition stored in that format and, secondly, whatever custom search folder I create in my code, teh restriction will not be displayed by OUtlook if the user were to modify teh search folder definition.&lt;/p&gt;
&lt;p&gt;Thanks!&lt;/p&gt;</description></item><item><title>Delete Search Folder in Outlook 2003</title><link>http://blogs.msdn.com/stephen_griffin/archive/2009/05/21/less-than-portable-search-folders.aspx#9725439</link><pubDate>Thu, 11 Jun 2009 03:38:22 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9725439</guid><dc:creator>Nick De Lancie</dc:creator><description>&lt;p&gt;Stephen:&lt;/p&gt;
&lt;p&gt;All for my own personal use, I am an inveterate Word and Outlook VBA amateur programmer, and reasonably accomplished, particularly on the Word side.&lt;/p&gt;
&lt;p&gt;I am stumped, however, by how to delete an existing Outlook search folder programatically (or, in fact, to open it as a folder in an explorer programatically) in Outlook 2003.&lt;/p&gt;
&lt;p&gt;I can enumerate all the search folders in my mailbox's store (and see that there are numerous folders of the tag form &amp;quot;Search Folder[x]&amp;quot; where [x] is either null or 1 to 24 in addition to the built-in search folders and those I have created, whether manually or through VBA) using CDO and MAPI stores, but for the life of me, I can't programatically delete the folder or otherwise deal with it.&lt;/p&gt;
&lt;p&gt;Any help would be much appreciated.&lt;/p&gt;
&lt;p&gt;Thanks,&lt;/p&gt;
&lt;p&gt;Nick De Lancie&lt;/p&gt;</description></item><item><title>re: (Less Than) Portable Search Folders</title><link>http://blogs.msdn.com/stephen_griffin/archive/2009/05/21/less-than-portable-search-folders.aspx#9726521</link><pubDate>Thu, 11 Jun 2009 16:17:47 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9726521</guid><dc:creator>Stephen Griffin</dc:creator><description>&lt;p&gt;Nick,&lt;/p&gt;
&lt;p&gt;I haven't tried to delete the actual search folders, but in this scenario, deleting the folder itself doesn't help. It's the folder definition, which is an item, that has to be wiped out.&lt;/p&gt;
&lt;p&gt;Steve&lt;/p&gt;
</description></item><item><title>re: (Less Than) Portable Search Folders</title><link>http://blogs.msdn.com/stephen_griffin/archive/2009/05/21/less-than-portable-search-folders.aspx#9736598</link><pubDate>Fri, 12 Jun 2009 20:48:59 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9736598</guid><dc:creator>Nick De Lancie</dc:creator><description>&lt;p&gt;Steve:&lt;/p&gt;
&lt;p&gt;Thank you for your reply.&lt;/p&gt;
&lt;p&gt;I probably should have been more specific before, but I think you almost certainly already know that executing, for a search folder &amp;quot;sfldr&amp;quot; identified by running through the InfoStore of the MAPI Session with the Finder EntryID to enumerate the search folders, the method sfldr.Delete only changes the text of the name of the search folder in the search folders display in the Outlook folder view list to italics, but the search folder is still &amp;quot;there&amp;quot; so that a new programmatic search with the same tag name given fails with &amp;quot;unable to create&amp;quot;.&lt;/p&gt;
&lt;p&gt;Since I need to delete the search folder definition item as you note above, do you know how that can programmatically be accessed in Outlook 2003, which does not have the PropertyAccessor and Table capabilities you utilized in your code example?&lt;/p&gt;
&lt;p&gt;Also, what is the programmatic methodology for displaying the found sfldr in a new explorer (so at least I could trap the cannot create folder error and display the existing one rather than deleting and recreating it, although this doesn't get to the clean-up problem of programmatically deleting multiple created search folders now no longer needed)?&lt;/p&gt;
&lt;p&gt;Again, any help would be much appreciated.&lt;/p&gt;
&lt;p&gt;Thanks, &lt;/p&gt;
&lt;p&gt;Nick&lt;/p&gt;</description></item><item><title>re: (Less Than) Portable Search Folders</title><link>http://blogs.msdn.com/stephen_griffin/archive/2009/05/21/less-than-portable-search-folders.aspx#9736671</link><pubDate>Fri, 12 Jun 2009 20:58:05 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9736671</guid><dc:creator>Stephen Griffin</dc:creator><description>&lt;p&gt;I don't think there's a way to delete the item with the Outlook 2003 object model. Of course, if you use MAPI, all things are possible.&lt;/p&gt;
</description></item></channel></rss>