title: Cannot implicitly convert type 'System.DateTime' to 'string'
body: <p>I am trying to output an excel file and part of it puts the value of createddate from a table called outofstock the line is currently putting a 0</p>
  
  <p>If I run this SQL it shows everything fine</p>
  
  <pre><code>select wo.email, wo.productid, wo.variantid,  p.NAME pname,  
         p.SKU psku, wo.createdon, pc.CategoryID, c.Name
  from woeosemails wo 
  join Product p with (nolock) on p.ProductID = wo.productid
  left join ProductCategory as pc (nolock) on p.ProductID=pc.ProductID
  left join Category as c (nolock) on pc.CategoryID=c.CategoryID
  order by wo.createdon, wo.email, wo.productid
  </code></pre>
  
  <p>The problem lies with this line in the aspx.cs file generating the output</p>
  
  <pre><code>createdon = DB.RSFieldDateTime(NotifyReader, "createdon"); 
  </code></pre>
  
  <p>I don't know what type (int, string etc) to place before. Within the SQL table the DataType is datetime but using this does not seem to work. </p>
  
  <p>Any thoughts?</p>
  
  <pre><code>string email = DB.RSField(NotifyReader, "email");
  int productid = DB.RSFieldInt(NotifyReader, "productid");
  int variantid = DB.RSFieldInt(NotifyReader, "variantid");
  string createdon = DB.RSFieldDateTime(NotifyReader, "createdon"); 
  string psku = DB.RSField(NotifyReader, "psku");
  string pname = DB.RSField(NotifyReader, "pname");
  string cname = DB.RSField(NotifyReader, "cname");
  </code></pre>