Forum Discussion

newbiexiii's avatar
newbiexiii
New Contributor
4 years ago

Reading values from excel file

My AUT exports excel files which contains dates and strings. I am trying to read the exported excel file but dates are read as encoded.
For instance, the excel has a column named Date and date format is 8/25/2016 11:13:52 AM but when I try to read this value with Excel object, I get

_x0038__x002F_25_x002F_2016_x0020_11:13:52_x0020_AM

How can I decode this to get the correct date format?

 

Code used to open and read excel file

 

var sheet = Excel.Open(filename).SheetByIndex(0);

sheet.Cell(7,2).Value;