If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Data Access, Manipulation & Batch Languages > ASP > Accessing Excel Spreadsheet in ASP

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 06-05-03, 09:11
h.bana h.bana is offline
Registered User
 
Join Date: Jun 2003
Posts: 2
Accessing Excel Spreadsheet in ASP

I'm accessing an Excel spreadsheet in ASP using ADO. In one of its columns, I have a mixture of Numeric and Alhphanumeric values, but majority of them are Numeric values. The problem is that ADO sets the Data Type of that column as Numeric by-default and hence it ignores all the Alphanumeric values in other rows of the same column. I have also tried the MAXSCANROWS settings in Extended Properties of the Connection String by setting its value to 16, but still it sets the Data Type as Numeric for that column, whereas I need it to be set to Alphanumeric.

Please tell me some possible solutions to this problem.
Reply With Quote
  #2 (permalink)  
Old 06-06-03, 00:43
Bullschmidt Bullschmidt is offline
Guru
 
Join Date: Jun 2003
Location: USA
Posts: 1,032
This is going to sound stupid but it worked for me once at least with a CSV file (which of course can be read and written to by Excel). Make the first row contain some letters instead of just numbers.
__________________
J. Paul Schmidt, Freelance Web and Database Developer
www.Bullschmidt.com
Access Database Sample, Web Database Sample, ASP Design Tips
Reply With Quote
  #3 (permalink)  
Old 06-06-03, 04:04
h.bana h.bana is offline
Registered User
 
Join Date: Jun 2003
Posts: 2
no success

Quote:
Originally posted by Bullschmidt
This is going to sound stupid but it worked for me once at least with a CSV file (which of course can be read and written to by Excel). Make the first row contain some letters instead of just numbers.
I tried your solution by entering Alphanumeric characters in very first row of the respective column of the Excel sheet, but still it didn't work out for me. The data type which ADO sets for this column is still Numeric, so the rows having Alphanumeric values are ignored.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On