title: Marking an email message as read using Exchange Web Services 2007
body: <p>I am subscribed to an email account using Exchange Web Services 2007 and processing attachments as new emails come in. I would like to mark those emails as "read" on the server after I'm done processing them, but I'm finding it's not as simple as setting the "IsRead" property to true. I've even tried the following:</p>
  
  <pre><code>Dim msg As EmailMessage
  msg.Load(New PropertySet({EmailMessageSchema.IsRead}))
  msg.IsRead = True
  </code></pre>
  
  <p>I tried this after finding out that I had to load specific schema properties if I wanted to interact with certain parts of the message (like attachments). I've also tried directly binding the message to a new object and loading additional properties:</p>
  
  <pre><code>Dim iID as ItemId = msg.Id
  Dim tmpMsg as EmailMessage = EmailMessage.Bind(service, iID, New PropertySet(BasePropertySet.FirstClassProperties, EmailMessageSchema.IsRead))
  tmpMsg.IsRead = True
  </code></pre>
  
  <p>I'm getting no luck. I've googled around and found <a href="http://blogs.msdn.com/b/vikas/archive/2007/11/30/howto-ews-update-isread-flag-for-items-using-exchange-web-services.aspx?PageIndex=2" rel="noreferrer">one MSDN blog example</a> that seems like it should work, but he's got some classes that I can't seem to find (like the <code>Microsoft.Exchange.WebServices.SetItemFieldType</code> class; all I've got in the <code>WebServices</code> namespace are the <code>Data</code> and <code>AutoDiscover</code> namespaces, no classes or anything). And since I can't find those classes or anything similar I'm kinda stuck. He also listed a DAV example but, again, his code uses classes I can't find in my version of the EWS dll (which is 14.0.0.0). I tried downloading the latest API from Microsoft but that seemed to be the same version as what I already have.</p>
  
  <p>So my question is, is there a way of marking an item as read using Exchange 2007 Web Services?</p>