title: MailMessage, difference between Sender and From properties
body: <p>I've been using the <code>System.Net</code> namespace ever since we switched from .NET Framework 1.1 to the 3.5 framework, but there&rsquo;s one thing that&rsquo;s been puzzling me since. What's the difference between the <code>Sender</code> and the <code>From</code> properties in the <code>MailMessage</code> class? </p>
  
  <p>Are they both the same, and if not is there a reason to use <code>Sender</code> together with <code>From</code>?</p>
  
  <p>For example:</p>
  
  <pre><code>Using m As New System.Net.Mail.MailMessage()
      m.Sender = New System.Net.Mail.MailAddress("test@test.com", "Name here")
      m.From = New System.Net.Mail.MailAddress("test@test.com", "Name here")
  
      m.Subject = "Test"
      m.Body = "Test"
  
      Dim client As New System.Net.Mail.SmtpClient("mymailserver.com")
      client.Send(m)
  End Using
  </code></pre>