title: Change From email address in MVCMailer 4.5
body: <p>Does anyone know how to change the from email address in code to override the web.config settings.</p>
  
  <p>What I'm trying to do is allow someone to complete an online form and when the recipicant receives the email, it will be from the senders email address.</p>
  
  <p>But at the momment it is just displaying the default in web.config.</p>
  
  <p>-----------------Web.config-------------------------</p>
  
  <pre><code>&lt;smtp from="some-email@gmail.com" deliveryMethod="SpecifiedPickupDirectory"&gt;
                  &lt;network host="localhost" /&gt;
                  &lt;specifiedPickupDirectory pickupDirectoryLocation="c:\temp\"/&gt;
              &lt;/smtp&gt;
  </code></pre>
  
  <hr>
  
  <pre><code>public virtual MvcMailMessage DirectotyEmail(string emailTo, string fromName, string arrivalDate, string departureDate, string message)
              {
              ViewBag.FromName        = fromName;
              ViewBag.ArrivalDate     = arrivalDate;
              ViewBag.DepartureDate   = departureDate;
              ViewBag.Message         = message;
              return Populate(x =&gt;
              {
                  x.Subject = "Accommodation Enquery form";
                  x.ViewName = "DirectoryEmail";
                  x.To.Add(emailTo.ToString());
                  //x.From.Address("test@email.com");
                  x.IsBodyHtml = true;
              });
              }
  </code></pre>
  
  <hr>
  
  <pre><code>X-Sender: some-email@gmail.com &lt;&lt; Need this to be the email that user entered when submitting form
  X-Receiver: test@mail.com
  MIME-Version: 1.0
  From: some-email@gmail.com &lt;&lt; Need this to be the email that user entered when submitting form
  To: test@mail.com
  Date: 26 Mar 2013 11:08:57 +0000
  Subject: Accommodation Enquery form
  Content-Type: text/html; charset=us-ascii
  Content-Transfer-Encoding: quoted-printable
  </code></pre>