title: Sending Datagridview to email
body: <p>i made a code that i can send an email to gmail.com with c# and it is working very well.
  Now i want to put my datagridview1 in the email body and send it.
  Somone can show me how i can do that?
  I searched a lot but i only found useless information and asp.net codes.</p>
  
  <p>Here is my atual code of sending an email .
  My datagridview name is : datagridview1</p>
  
  <pre><code> private void btnSend_Click_1(object sender, EventArgs e)
      {
          // Create a message with datagridview contents in its body and set up the recipients.
  
  
  
  
  
          var client = new SmtpClient("smtp.gmail.com", 587);
          client.EnableSsl = true;
          client.Credentials = new NetworkCredential("jpbritopoker@gmail.com", "*****");
  
          var mail = new MailMessage();
          mail.From = new MailAddress("youraccount@yahoo.com");
          mail.To.Add("jpbritopoker@gmail.com");
          mail.Subject = "This is the subject of the mail";
          mail.Body = "Here i want my datagridview1";
          client.Send(mail);
  
  
      }
  </code></pre>