+ Reply to Thread
Results 1 to 2 of 2

Indirect function problem

  1. #1
    Registered User
    Join Date
    05-25-2012
    Location
    Singapore
    MS-Off Ver
    Excel 2007
    Posts
    1

    Indirect function problem

    Hi all,

    I've been trying to reference to cells in another open files and have been attempting to use the indirect function. =INDIRECT("["&G7&"]SHEET1!F4")
    Where G7 is the file name e.g. Book1.xls and F4 is the cell from which i wish to reference from. However, I have a macro which generates the list of open files in columns. The indirect function returns a REF! when i link my indirect functions to the results of the macro and the indirect function only works when I manually type in the file name. This does not help as the initial intention of creating a macro is the automate the process (to capture data from cells of workbooks which are opened by a user). I do not understand why this situation is occurring. I appreciate if any help or assistance of any sort can be rendered.

    Shawn

  2. #2
    Forum Expert dilipandey's Avatar
    Join Date
    12-05-2011
    Location
    Dubai, UAE
    MS-Off Ver
    1997 - 2016
    Posts
    8,191

    Re: Indirect function problem

    Hi Shawn,

    Try including the file name with entire path for Indirect function..
    and yes, Indirect function fetches data from other workbooks if they are open.


    Regards,
    DILIPandey

    <click on below 'star' if this helps>
    DILIPandey, Excel rMVP
    +919810929744 (India), +971528225509 (Dubai), [email protected]

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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