Re: Why ADO with Excel formats text data with only numbers ?



JoseValencia wrote:
I'm using ADO.NET to read an excel file. In one of the columns I have
data that can be a mix of numbers and letters, but sometimes there
are only numbers. The value I get for the number 300015532 is
3.00016e+008. I want to capture the actual value 300015532 .
Anybody has fixed it?

Here is the connection string used in the datasource:
Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\\file.xls;Extended
Properties="Excel 8.0;IMEX=1;"

Here is a sample of values of such column:
300014AKB
300014AKQ
3000152TQ
300014AGY
300015532 --> This failed
Will this help?
http://groups.google.com/group/comp.databases.ms-sqlserver/browse_frm/thread/1678755b6673b51a/72f03347c3c0dbd9?lnk=st&q=%22Excel+8.0%3BIMEX%3D1%3B%22+number+as+text&rnum=8&hl=en#72f03347c3c0dbd9
--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.


.



Relevant Pages

  • Re: Saving mail merged letter seperately then emailing
    ... Please reply to the newsgroup unless you wish to avail yourself of my ... Doug Robbins - Word MVP ... While Counter < Letters ... when i clicked on the word add-in template it gave me ...
    (microsoft.public.word.mailmerge.fields)
  • Re: Saving mail merged letter seperately then emailing
    ... Please reply to the newsgroup unless you wish to avail yourself of my ... Doug Robbins - Word MVP ... While Counter < Letters ... when i clicked on the word add-in template it gave me ...
    (microsoft.public.word.mailmerge.fields)
  • Re: Saving mail merged letter seperately then emailing
    ... Please reply to the newsgroup unless you wish to avail yourself of my ... Doug Robbins - Word MVP ... While Counter < Letters ... when i clicked on the word add-in template it gave me ...
    (microsoft.public.word.mailmerge.fields)
  • Re: Ok im sorry here are some for you
    ... Dontaitchicago@xxxxxxx appears to have caused the following letters to be ... I realize of course that my post is an exercise in futility, as the spammer ... "But some people in this newsgroup might want to buy them!" ... Well, actually, an FBI Special Agent did take my photograph ...
    (rec.music.classical.recordings)
  • Re: Perplexed - who should I believe?
    ... No-one has bothered to ask HOW I came across a URL with the case of letters ... on a newsgroup. ... Browser window into Notepad. ... It's easier to trust the http://go.microsoft.com/?linkid=4538415 links, ...
    (microsoft.public.security)