read excel

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • ash

    read excel

    i use the following code to read excel
    Set ExcelConn = Server.CreateOb ject("ADODB.Con nection")
    Set ExcelRS = Server.CreateOb ject("ADODB.Rec ordset")
    ......
    sSQL = "SELECT * FROM [Sheet1$]"
    set ExcelRS = ExcelConn.Execu te(sSQL)

    it work fine for those cell that contained string , but once the cell is numeric, i cant get anything in the cell. How can i solve this problem.

    many thx
  • Ray Costanzo [MVP]

    #2
    Re: read excel

    Try adding "IMEX=1;" to your connection string. If you're not sure how or
    where, post your connection string and I'll modify it for you.

    Ray at work

    "ash" <ash@gmail.comw rote in message
    news:%23eBfTAi3 GHA.3464@TK2MSF TNGP03.phx.gbl. ..
    i use the following code to read excel
    Set ExcelConn = Server.CreateOb ject("ADODB.Con nection")
    Set ExcelRS = Server.CreateOb ject("ADODB.Rec ordset")
    ......
    sSQL = "SELECT * FROM [Sheet1$]"
    set ExcelRS = ExcelConn.Execu te(sSQL)

    it work fine for those cell that contained string , but once the cell is
    numeric, i cant get anything in the cell. How can i solve this problem.

    many thx


    Comment

    Working...