Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 567615
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T13:06:07+00:00 2026-05-13T13:06:07+00:00

I have an excel sheet I need to import in my Access database. The

  • 0

I have an excel sheet I need to import in my Access database.
The sheet looks like this:

DATE RECEPTION  DENOMINATION        ITEM N°     QUANTITE RECUE
06/01/2010  DVD-Sex & the City  PCR-PA21550167  5
06/01/2010  DVD-Avatar Natie 2  PCR-PA21550209  10

I then transfer this file into the database using adodb:


Dim rs2 As New ADODB.Recordset
Dim cnn2 As New ADODB.Connection
Dim cmd2 As New ADODB.Command
Dim intField As Integer
Dim strFile As String

strFile = fncOpenFile
If strFile = "" Then Exit Sub

With cnn2
    .Provider = "Microsoft.Jet.OLEDB.4.0"
    .ConnectionString = "Data Source=" & strFile& "; " & "Extended Properties=Excel 8.0"
    .Open
End With

Set cmd2.ActiveConnection = cnn2
cmd2.CommandType = adCmdText
cmd2.CommandText = "SELECT * FROM [PCR$]"
rs2.CursorLocation = adUseClient
rs2.CursorType = adOpenDynamic
rs2.LockType = adLockOptimistic

rs2.Open cmd2

While Not rs2.EOF
        strNaam = rs2.Fields(3).Value
Loop

Now my problem: certain fields have text in them.
The field value should then be item0001, but it’s reportedly NULL

When the field has a regular number it works fine.

The strange thing is: there are other text fields in the sheet and they work FINE.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T13:06:07+00:00Added an answer on May 13, 2026 at 1:06 pm

    Be more specific in your Extended Properties portion (and don’t omit inner quotes there).

    In particular, try Extended Properties="Excel 8.0;HDR=Yes;IMEX=1" to allow mixed numbers&text data.

    More details at http://connectionstrings.com/.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a need to generate an excel sheet report which looks like the
I have excel sheet that looks something like this.. A B C ...K.....P Q
I have a Excel sheet with two columns and I need to create new
I have an excel sheet laid out like so: +--id---+--val--+--timestamp--+ | 01 | 1.2
MY scenario is... I have 6,000 datas in Excel Sheet.. I try to import
Hai i have an excel sheet, in that i need to calculate some values
I have an excel sheet which has about 150,000 records, operations like find replace,
In share point 2010, I would like to have an excel sheet(2007) in sharepoint
I have a Gridview like excel sheet. I use it to update and insert
need to open an excel sheet and then go an to cell range like

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.