Results 1 to 4 of 4
  1. #1
    2 Star Lounger
    Join Date
    Aug 2005
    Posts
    132
    Thanks
    0
    Thanked 0 Times in 0 Posts

    importing from access to excel (Access 2000)

    I have a corrupt database and i can neither open it nor import it from a blank database.I want to try importing the data into an excel file. Infortunately my excel programme is not full and i have no disc to load it.Therefore when i try to import from data/import external data in the excel worksheet, i get the message to insert the disc.Can you help me with some code, perhaps also transfer datasheet, to import the tables ? For example, the table product ? And where can i put the command in the excel sheet or not ?

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: importing from access to excel (Access 2000)

    I don't understand. If you can't start Excel, how are you going to run code in Excel?

    (I assume that you can't run code in the Access database, since it is corrupt)

  3. #3
    2 Star Lounger
    Join Date
    Aug 2005
    Posts
    132
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: importing from access to excel (Access 2000)

    i open the excel sheet, then i click on data/get external data/New database query. Then i get the message : This feature is not currently installed.Would you like to install now .
    Do i have any hope to do something ?

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: importing from access to excel (Access 2000)

    I don't know if the following will work, but it's worth a try:
    - Start Excel.
    - Activate the Visual Basic Editor (Alt+F11)
    - Set a reference to the Microsoft DAO 3.6 Object Library (Tools | References...)
    - Create a module (Insert | Module)
    - Create a macro that opens a DAO.Database object, opens a DAO.Recordset object on a table in the database, then uses CopyFromRecordset to copy the data to Excel.
    - See the built-in help for CopyFromRecordset for an example.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •