+ Reply to Thread
Results 1 to 5 of 5

ADO with closed workbook

  1. #1
    Registered User
    Join Date
    08-10-2020
    Location
    Netherlands
    MS-Off Ver
    2019
    Posts
    81

    Question ADO with closed workbook

    I recently started working with ADO to access a closed workbook and put the retrieved data in an Array.

    I have two questions regarding this:

    1. How can I count the number of sheets in this closed workbook?
    2. If I don't know the sheet NAME of the data sheet but I DO know it's the first sheet, how should I change this query?

    Please Login or Register  to view this content.
    Many thanks in advance!

  2. #2
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,519

    Re: ADO with closed workbook

    Using DAO
    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    08-10-2020
    Location
    Netherlands
    MS-Off Ver
    2019
    Posts
    81

    Re: ADO with closed workbook

    Jindon, thank you for your quick reply (again)

    Do you think I can combine your DAO code with my ADO code?
    I already started using ADO, or do you think I only should use DAO instead...?

    This is all pretty new to me ;-)

  4. #4
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,519

    Re: ADO with closed workbook

    I would just use the sheet name with ADO.
    so the line should be like
    Please Login or Register  to view this content.
    Last edited by jindon; 05-27-2021 at 04:08 AM.

  5. #5
    Registered User
    Join Date
    08-10-2020
    Location
    Netherlands
    MS-Off Ver
    2019
    Posts
    81

    Re: ADO with closed workbook

    Quote Originally Posted by jindon View Post
    I would just use the sheet name with ADO.
    so the line should be like
    Please Login or Register  to view this content.
    Ah, didn't know I could combine them!
    Thanks again man, I'll try that for sure!

+ 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] VB Code to copy data from closed workbook to another closed workbook
    By rizmomin in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-10-2020, 01:40 PM
  2. [SOLVED] VB Code to copy closed workbook to another closed workbook
    By rizmomin in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 03-03-2019, 12:02 PM
  3. Export data with two Criteria values from closed workbook to closed workbooks VBA
    By julielara in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-07-2016, 01:56 PM
  4. need vba to copy sheets from closed workbook and paste into all closed wb's
    By breadwinner in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-20-2016, 01:25 PM
  5. Update Cell Value from a Closed Workbook to Another Closed Workbook
    By glennchung in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-17-2014, 04:44 PM
  6. Replies: 0
    Last Post: 03-27-2014, 12:38 PM
  7. Copy One Sheet From One Closed Workbook To Another Closed WB
    By teshiburu1988 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-04-2009, 11:49 AM

Tags for this Thread

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