+ Reply to Thread
Results 1 to 10 of 10

Import Access database recordset into Excel

  1. #1
    Registered User
    Join Date
    03-16-2021
    Location
    Woudrichem, the Netherlands
    MS-Off Ver
    2016
    Posts
    5

    Question Import Access database recordset into Excel

    Hello,
    my code to put access data in an excel workbook no longer works. the access database is of the type .accdb. I use office 2016 can someone help me with this?

    Code:
    Please Login or Register  to view this content.
    Moderator's note: Please take the time to review our rules. There aren't many, and they are all important. Rule #2 requires code tags. I have added them for you this time because you are a new member. --6StringJazzer
    Last edited by 6StringJazzer; 03-16-2021 at 11:59 AM.

  2. #2
    Banned User!
    Join Date
    01-17-2021
    Location
    Omaha, NE
    MS-Off Ver
    office 2016
    Posts
    211

    Re: Import Access database recordset into Excel

    well, what you mean 'it not working'? did it break and work before? also i believe you have to make records visible. you do that by moving to last record and then back to first. if you do not do this only first record is seen by environment. loop ends after 1.

  3. #3
    Registered User
    Join Date
    03-16-2021
    Location
    Woudrichem, the Netherlands
    MS-Off Ver
    2016
    Posts
    5

    Re: Import Access database recordset into Excel

    It works with an .mdb file but not with an .accdb file

  4. #4
    Banned User!
    Join Date
    01-17-2021
    Location
    Omaha, NE
    MS-Off Ver
    office 2016
    Posts
    211

    Re: Import Access database recordset into Excel

    hmmmm.....maybe the accdb file needs to have done what i said?

  5. #5
    Registered User
    Join Date
    03-16-2021
    Location
    Woudrichem, the Netherlands
    MS-Off Ver
    2016
    Posts
    5

    Re: Import Access database recordset into Excel

    this is the complete code

    Please Login or Register  to view this content.

  6. #6
    Banned User!
    Join Date
    01-17-2021
    Location
    Omaha, NE
    MS-Off Ver
    office 2016
    Posts
    211

    Re: Import Access database recordset into Excel

    the code did not change. the code that is issue for you. in the last post, it looked the same as previous code you posted. so not sure what to say. you never did say though what was not working. line of code? you step line by line with it? other issue that see is that you are not destroy memory. maybe that is it?

  7. #7
    Registered User
    Join Date
    03-16-2021
    Location
    Woudrichem, the Netherlands
    MS-Off Ver
    2016
    Posts
    5

    Re: Import Access database recordset into Excel

    Attached the files with mdb and accdb extension and the corresponding excel files
    Attached Files Attached Files

  8. #8
    Banned User!
    Join Date
    01-17-2021
    Location
    Omaha, NE
    MS-Off Ver
    office 2016
    Posts
    211

    Re: Import Access database recordset into Excel

    your original code for me resulted in first image below. when i changed that code to this
    Please Login or Register  to view this content.
    i got what you see in second image below. now, 'opendatabase' has 3 methods guess

    https://docs.microsoft.com/en-us/off...ase-method-dao

    https://docs.microsoft.com/en-us/off...s.opendatabase

    https://docs.microsoft.com/en-us/off...ase-method-dao

    but one those is for inside access. and one them applies to treating workbooks like databases. this one

    https://docs.microsoft.com/en-us/off...s.opendatabase

    that one i used to test. that's why second image below looks like that.

    so, issue might be that you swtiched from 32 bit office to 64 bit office, or could be that now you using later version of office. look at articles i post. see that years? they only apply to 2013. so that be the problem maybe??
    Attached Images Attached Images

  9. #9
    Registered User
    Join Date
    03-16-2021
    Location
    Woudrichem, the Netherlands
    MS-Off Ver
    2016
    Posts
    5

    Re: Import Access database recordset into Excel

    THX the problem is resolved

  10. #10
    Banned User!
    Join Date
    01-17-2021
    Location
    Omaha, NE
    MS-Off Ver
    office 2016
    Posts
    211

    Re: Import Access database recordset into Excel

    K good.......nice!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Import Filtered Recordset from Access Database
    By TubbzUK in forum Excel Programming / VBA / Macros
    Replies: 16
    Last Post: 04-06-2015, 06:32 PM
  2. [SOLVED] VBA in Excel to import Access Database
    By jmzis4me in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 09-26-2014, 04:39 PM
  3. Import relational Access database into Excel 2007?
    By OldManExcellor in forum Excel General
    Replies: 0
    Last Post: 09-01-2014, 08:58 AM
  4. Import Excel to Relational Access Database
    By jschen77 in forum Access Tables & Databases
    Replies: 2
    Last Post: 03-05-2013, 02:10 PM
  5. Is it possible to import data to excel from an access database online?
    By Rob* in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-16-2012, 04:22 AM
  6. Manipulating Access database Recordset
    By mbarisic in forum Access Programming / VBA / Macros
    Replies: 1
    Last Post: 05-22-2012, 06:59 AM
  7. Import Access Database info to Excel???
    By jwr in forum Excel General
    Replies: 4
    Last Post: 08-16-2005, 01:17 PM

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1