Problem reading with Percentage values

  • Thread starter Problem reading with Percentage values
  • Start date
P

Problem reading with Percentage values

Hi,

I am using OleDB provider to read excel file. I am facing the
problem when reading percentage values from some excel sheets (very rarely).
Suppose a cell has 42.3%, when reading the value it comes like 0.423... but
while reading other Workbook's excel sheets (for those actual value is
24.7%), it reads properly like 24.7.... When i checked excel sheet cell
Format for both Workbooks, it is same with Percentage with 1 decimal.

Connection String i am using to read excel sheet is


Provider=Microsoft.ACE.OLEDB.12.0; Data Source='"

+ strFilePath.Replace("'", "''") + "';Extended Properties=Excel 12.0;



where strFilePath provides the path to excel document.


Thanks
Anil
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top