Hi,

I developed an application in visual c# .net
This application reades an excel file and displays its contents into a dataGrid (OleDbDataAdapter).
What I discovered is that if a cell in excel has a constant, then i can retrieve its contents. Also, if a cell has a formula (e.g. =K10) and K10 has a constant then it is also fine.
But if the cell's properties are of Custom type, with type, say hh:mm, then i cannot get the contents to the dataGrid.

Do you know why this is happening? Has anyone found a workaround for it?

Thanks in advance
Kostas

--------------------------------
From: Kostas Alifantis

-----------------------
Posted by a user from .NET 247 (http://www.dotnet247.com/)

<Id>ICkne+DCCUWlYeHpuluf+w==</Id>

Re: excel formulas and visual c# .net by Paul

Paul
Fri Mar 11 10:53:59 CST 2005

On Fri, 11 Mar 2005 06:22:32 -0800, Kostas Alifantis via .NET 247 <anonymous@dotnet247.com> wrote:

¤ Hi,
¤
¤ I developed an application in visual c# .net
¤ This application reades an excel file and displays its contents into a dataGrid (OleDbDataAdapter).
¤ What I discovered is that if a cell in excel has a constant, then i can retrieve its contents. Also, if a cell has a formula (e.g. =K10) and K10 has a constant then it is also fine.
¤ But if the cell's properties are of Custom type, with type, say hh:mm, then i cannot get the contents to the dataGrid.
¤
¤ Do you know why this is happening? Has anyone found a workaround for it?
¤

Could you post your connection string? It's possible that the addition of the IMEX parameter may
resolve your problem.


Paul
~~~~
Microsoft MVP (Visual Basic)