title: ServiceObjectPropertyException on an EWS Appointment
body: <p>i'm using the EWS API to export an appointment to a user's exchange calender. It was working fine but I noticed in the appointment the html was not formatted properly with the table aligning and such. So I tried setting the appointment body type property to HTML but got the ServiceObjectPropertyException saying "You must load or assign this property before you can read its value" on that line where I set the property.</p>
  
  <pre><code>                User SelectedUser = UserController.GetExchangeCredentials(UserID);
  
                  //If they have their exchange credentials setup then create the appointment in their exchange calender
                  if (SelectedUser.ExchangeUsername != String.Empty)
                  {
                      Client ClientInfo = ClientController.GetContactInfoForCalenderAppointment(int.Parse(btn_SubmitNextContactDate.CommandArgument.ToString()), int.Parse(ddl_Contact.SelectedValue));
  
                      //Setup the exchange service with the user credentials of that receiving the appointment
                      ExchangeService Service = new ExchangeService(ExchangeVersion.Exchange2007_SP1);
                      Service.UseDefaultCredentials = false;
                      Service.Credentials = new WebCredentials(SelectedUser.ExchangeUsername, SelectedUser.ExchangePassword, SelectedUser.ServerDomain);
                      Service.AutodiscoverUrl(SelectedUser.Email);
  
                      //Create the appointment
                      Microsoft.Exchange.WebServices.Data.Appointment Appointment = new Microsoft.Exchange.WebServices.Data.Appointment(Service);
                      Appointment.Body.BodyType = BodyType.HTML;
                      Appointment.Subject = "Next Contact Date for " + OperatingName.Text;                        
                      Appointment.Body = "&lt;table&gt;&lt;tr&gt;&lt;td&gt;&lt;b&gt;Client Name:&lt;/b&gt;&lt;/td&gt;&lt;td&gt;" + ClientName.Text + "&lt;/td&gt;&lt;/tr&gt;";
                      Appointment.Body += "&lt;tr&gt;&lt;td&gt;&lt;b&gt;Operating Name:&lt;/b&gt;&lt;/td&gt;&lt;td&gt;" + OperatingName.Text + "&lt;/td&gt;&lt;/tr&gt;";
                      Appointment.Body += "&lt;tr&gt;&lt;td&gt;&lt;b&gt;Service:&lt;/b&gt;&lt;/td&gt;&lt;td&gt;" + ddl_ServiceType.SelectedItem.Text + "&lt;/td&gt;&lt;/tr&gt;";
                      Appointment.Body += "&lt;tr&gt;&lt;td&gt;&lt;b&gt;Contact Method:&lt;/b&gt;&lt;/td&gt;&lt;td&gt;" + ddl_ContactMethod.SelectedItem.Text + "&lt;/td&gt;&lt;/tr&gt;";
                      Appointment.Body += "&lt;tr&gt;&lt;td&gt;&lt;b&gt;Contact Name:&lt;/b&gt;&lt;/td&gt;&lt;td&gt;" + ddl_Contact.SelectedItem.Text + "&lt;/td&gt;&lt;/tr&gt;";
                      Appointment.Body += "&lt;tr&gt;&lt;td&gt;&lt;b&gt;Contact Phone:&lt;/b&gt;&lt;/td&gt;&lt;td&gt;" + ClientInfo.Contacts[0].Phone + "&lt;/td&gt;&lt;/tr&gt;";
                      Appointment.Body += "&lt;tr&gt;&lt;td&gt;&lt;b&gt;Contact Email:&lt;/b&gt;&lt;/td&gt;&lt;td&gt;" + ClientInfo.Contacts[0].Email + "&lt;/td&gt;&lt;/tr&gt;";
                      Appointment.Body += "&lt;tr&gt;&lt;td&gt;&lt;b&gt;Client Address 1:&lt;/b&gt;&lt;/td&gt;&lt;td&gt;" + ClientInfo.Address1 + "&lt;/td&gt;&lt;/tr&gt;";
                      Appointment.Body += "&lt;tr&gt;&lt;td&gt;&lt;b&gt;Note:&lt;/b&gt;&lt;/td&gt;&lt;td&gt;" + txt_NextContactDateNote.Content + "&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;";
                      Appointment.Start = DateTime.Parse(txt_NextContactDate.Text);
                      Appointment.End = DateTime.Parse(txt_NextContactDate.Text);
                      Appointment.Save(SendInvitationsMode.SendToNone);
                  }                
  </code></pre>