title: convert date time to format ddd MM/dd/yyyy HH:mm:ss
body: <p>In the below code snippet I'am passing string value "item.Date" to string "Date"
  I wanted to convert it to this format <code>ddd MM/dd/yyyy HH:mm:ss</code>.</p>
  
  <p>converting to string and as well the above format was not going well i guess. </p>
  
  <p>I tried using:</p>
  
  <pre><code>DateTime dateformatted =  DateTime.ParseExact(item.Date, "ddd dd MMM yyyy h:mm tt", null);
  </code></pre>
  
  <p>it showed error. Can anyone help</p>
  
  <pre><code>foreach (var item in data)
  {
      model.Add(new MailDetailDTO
      {
          Attributes = item.Attribute1,
          Date = item.Date,
          From = item.SentFrom,
          FromOrg = item.OrganizationName,
          IsConfidential = item.IsConfidential,
          MailID = item.MailHeaderID,
      }
  }
  </code></pre>