title: Get dateTime in DB and convert to string and add in excel c#
body: <p>I get datetime from database SQL, and convert to string using  <code>table.Rows.Add(CreatedDate.ToString(&quot;dd/MM/yyyy&quot;, System.Globalization.CultureInfo.InvariantCulture));</code>
  when i open the excel i have diferents formats of dates, and the excel filters had date when it should have only the years as shown in the results in th filters:</p>
  <p><img src="https://i.stack.imgur.com/1s8aj.png" alt="Date format inconsistent" /></p>
  <p><a href="https://i.stack.imgur.com/tFy5x.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/tFy5x.png" alt="date filters error" /></a></p>