title: Setting an Outlook mailitem's category programmatically?
body: <p>There doesn't seem to much information or any good code samples for setting an Outlook 2007 MailItem's categories programmatically.</p>
  
  <p><a href="http://msdn.microsoft.com/en-us/library/microsoft.office.interop.outlook._mailitem.categories.aspx" rel="noreferrer">MSDN has a limited page</a>, and mentions using VB's <strong>Split</strong> function, saying more or less "<em>you're on your own from here onwards, so sort it out yourself</em>".</p>
  
  <p>So far as I can tell we manipulate the Categories as a comma delimited string property of the mailitem. It seems a bit primitive, is that all there is to it?</p>
  
  <p>Does everyone just dig out their library of string functions and parse the Categories property, trusting not to get in a muddle when multiple categories are set for a single mailitem and (heaven forbid) categories are renamed?</p>