473,395 Members | 1,583 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Excel data mismatch

I am having a problem in reading the values from the excel sheet in ASP .Net.
I am using the following connection string to read values from rows from an
excel sheet into a dataset. One of the columns contains alpha-numeric values
i.e. ABCDE12345 When accessing the value of this cell it returns "" (empty
string).

I am using the following connection string:
string strConn="Provider=Microsoft.Jet.OLEDB.4.0;"+"Data
Source="+filepath+";"+"Extended Properties=Excel 8.0;";

I have tried adding combinations of the following also.
HDR=YES;IMEX=1;ImportMixedTypes=Text;

The exception I get after adding the above code with my above connection
string is "No installable ISAM".

Does anyone have experience with this problem?

--
Kumar.A.P.P
Software Engineer, Infosys Technologies Limited.
http://techaid.wordpress.com/
Oct 12 '07 #1
1 1376
"Kumar.A.P.P" <Ku******@discussions.microsoft.comwrote in message
news:82**********************************@microsof t.com...
I am using the following connection string:
string strConn="Provider=Microsoft.Jet.OLEDB.4.0;"+"Data
Source="+filepath+";"+"Extended Properties=Excel 8.0;";

I have tried adding combinations of the following also.
HDR=YES;IMEX=1;ImportMixedTypes=Text;
Extended properties need to be surround in quotes:

string strConn = "Provider=Microsoft.Jet.OleDB.4.0;" + "Data
"Source=" + filepath + ";" + "Extended Properties=\"Excel
8.0;HDR=YES;IMEX=1;ImportMixedTypes=Text \"";
--
Mark Rae
ASP.NET MVP
http://www.markrae.net

Oct 12 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: deko | last post by:
So I've decided to convert from Early Binding to Late Binding. Now that I've been baptized, I need some instruction in the faith. My former ways were thus: Dim xlapp As Excel.Application Set...
5
by: Alfredo Magallón Arbizu | last post by:
Hi, I have an ASP.NET app that works perfectly in Windows Server 2003, but fails in Windows 2000. It fails when trying to read the data in an Excel Workbook (range.value)... The error is: ...
2
by: Aaron | last post by:
I am trying to design an application in Visual Studio that will allow a user to select a spreadsheet, pass in some parameters, and run macros in the spreadsheet that depend on the parameters. I was...
2
by: jason.teen | last post by:
Hi, I am having trouble importing a spreadsheet from Excel into an Access Database. I have noticed that even specifying the Cell Type of the Excel Data Cell, When I import it, still get...
1
by: wasishincar | last post by:
Hi all, I wrote a small app, which could read text file and fill the data from text file to a newly created excel file. It works fine on my computer, but did not succeed on someone's. I caught...
5
by: Lara1 | last post by:
Hi, I'm a total beginner to VBA, so please bear with me if I seem a bit dense. What I'm Trying to Achieve I'm trying to write a procedure in Excel, which is supposed to - look at the pH...
0
by: Michel Walsh | last post by:
I got the following error: ============= Type mismatch. (Exception from HRESULT: 0x80020005 (DISP_E_TYPEMISMATCH)) ============= when using Interop.Excel.Run. The relevant code is from...
5
by: kashif73 | last post by:
I have an application which updates record from my excel sheet into the MS SQL server DB. Thefirst line of my excel sheet has the column names of my database table. The problem arises with DATE...
1
by: House817 | last post by:
I consistently get an overflow error at the "SOxBenefits =" (source code below), while coding in a macros from within Excel, Microsoft XP. I've tried the following: 1. setting a variable equal to...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.