title: How to read email body in a CRM 2011 plugin
body: <p>I have created a plugin which reads the body (description) of the email. But it is giving me error when I try to read something from the plugin. It gives me NullReferenceException. I have registered the plugin on the creating of the new email activity (post-create). The subject field in the email entity is of Single Line of text but the email body(description) is multiple line of text. I am able to read the subject but not able to read email body. Below is the code I am using:</p>
  
  <pre><code>var body = email_entity["description"];
  </code></pre>
  
  <p>I guess that the e-mail body stores data in the form of string array. When I use the below piece of code but didn't assigned the value to any variable I got no errors.</p>
  
  <pre><code>var body = email_entity["description"];
  string[] desc = (string[])body;
  </code></pre>
  
  <p>Now if I use desc[0] to set the value in a variable it throws me the same NullreferenceException.</p>
  
  <p>I don't know how to read the value from the multiple lines of text field in a plugin. I tried above but it is of no use.</p>
  
  <p>Does anyone has any idea what I am missing or doing wrong?</p>
  
  <p>Thanks!</p>