Hi,
I have the following data in a excel csv file:
Date,Time,TempOut
3/17/2011,00:30,73.3
However, if I load it using:
ExclConn.ConnectionString = @"Provider=Microsoft.Jet.OLEDB.4.0;" +
"Data Source=" + dir + ";" +
"Extended Properties=\"text;HDR=Yes;FMT=Delimited\"";
Then:
string Data = "SELECT * FROM [" + FileName + "]";
OleDbDataAdapter dtadpt = new OleDbDataAdapter(Data, ExclConn);
//Create table
dtadpt.Fill(dt);
If I display,
dt.Rows[0][1].ToString()
It shows 12/30/1899 12:30 AM instead just 00:30.
Any solution to this?