+ Reply to Thread
Results 1 to 4 of 4

How to reference open workbook that ends with EFTY

  1. #1
    Forum Contributor
    Join Date
    09-30-2015
    Location
    LA my baby
    MS-Off Ver
    2013
    Posts
    727

    How to reference open workbook that ends with EFTY

    Hello. I will run code that opens 4 workbooks. How can I run code on specific workbooks only based on ending characters?

    For example:

    Workbooks("1234567EFTY").Sheets("Sheet1").Copy _

    just reference based on EFTY. Thanks.

  2. #2
    Forum Guru Winon's Avatar
    Join Date
    02-20-2007
    Location
    East Rand, R.S.A.
    MS-Off Ver
    2010
    Posts
    6,113

    Re: How to reference open workbook that ends with EFTY

    Hello stephme55,

    I believe it would depend on a few qualifications, for instance, are all the Workbooks in the same Folder/Directory, and will the last characters of said Workbooks only contain unique 4 trailing characters?

    Regards.
    Please consider:

    Be polite. Thank those who have helped you. Then Click on the star icon in the lower left part of the contributor's post and add Reputation. Cleaning up when you're done. If you are satisfied with the help you have received, then Please do Mark your thread [SOLVED] .

  3. #3
    Forum Contributor
    Join Date
    09-30-2015
    Location
    LA my baby
    MS-Off Ver
    2013
    Posts
    727

    Re: How to reference open workbook that ends with EFTY

    Yes they are all in same folder. No, in this case it will be EFTY, FA, REMIT, and RMT. But I want to activate a specific workbook based on it's ending characters (this might be the better question). So if I do a loop through all workbooks, to open them all. I can then reference the specific one that I want with the last letters (because the initial numbers will vary).

  4. #4
    Forum Guru Winon's Avatar
    Join Date
    02-20-2007
    Location
    East Rand, R.S.A.
    MS-Off Ver
    2010
    Posts
    6,113

    Re: How to reference open workbook that ends with EFTY

    Hi stephme55,

    Thank you for the feedback, and clarification. It helps a lot.

    Unlike some Forum Members who may have a ready answer, I would need some time to test a possible working solution.

    I shall get back to you as soon as I can.

    Regards.

+ 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] Help with VBA - VLookup to an open workbook with a set reference
    By JordanjAllen in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-21-2016, 02:38 PM
  2. Need Macro to check and see if PDF file is already open and if so then ends code
    By eleiprecht in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 10-10-2012, 11:38 AM
  3. Open a workbook using a cell reference
    By Grouhoule in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-16-2012, 02:34 PM
  4. Open a workbook from cell reference
    By george1982 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-23-2008, 04:49 AM
  5. Activating an Open Workbook without using the whole filename as a reference
    By jlejehan in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-02-2006, 02:58 AM
  6. Circular reference in an open workbook
    By Joe Cletcher in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-03-2006, 08:55 AM
  7. [SOLVED] Open an existing workbook and reference it
    By TimT in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-12-2005, 01:05 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