Getting #REF! on using indirect function


Board Regular
Jan 31, 2007
Hi all,
I have a workbook which has a sheet namely "Working". This sheet has in its Column G ranges referring to several other worksheets in the same workbook eg(ABCD!$A$1:$IA$35).
In Column I there is an hlookup throughout which uses the corresponding range present in Column B as the table_array using indirect function for eg(=HLOOKUP($E2,INDIRECT($G2),15,0).
Now my problem is that I am getting the error #REF! for some row-items. All the corresponding worksheets for these row-items are present in the workbook. None of them is hidden or very-hidden.
Any idea why this could be happening? Any help will be highly appreciated !!

Thanks in advance,
Nachiket Pendharkar.

Some videos you may like

Excel Facts

Show numbers in thousands?
Use a custom number format of #,##0,K. Each comma after the final 0 will divide the displayed number by another thousand


Well-known Member
Aug 21, 2005
examine the range given by the corresponding cell in column G and look for some error values like #N/A or #ref etc..

for e.g check the cells A1 to IA35 in sheet ABCD.


Board Regular
Jan 31, 2007
Hi Venkat,
Thanks for your reply. Actually the problem was that some of my worksheet names were containing hyphens in between
(eg RA-563!$A$1:$IA$35). So may be excel was considering '563' alone as the worksheet name and hence it was throwing the error.
I solved the problem by putting single inverted commas at the begining and at the end of the worksheet names(eg 'RA-563'!$A$1:$IA$35). Thereafter all the values were displayed.

Thanks anyway for spending your precious time on this !!

Nachiket Pendharkar.

Subscribe on YouTube

Watch MrExcel Video

Forum statistics

Latest member

This Week's Hot Topics

  • Turn fraction around
    Hello I need to turn a fraction around, for example I have 1/3 but I need to present as 3/1
  • TIme Clock record reformatting to ???
    Hello All, I'd like some help formatting this (Tbl-A)(Loaded via Power Query) [ATTACH type="full" width="511px" alt="PQdata.png"]22252[/ATTACH]...
  • TextBox Match
    hi, I am having a few issues with my code below, what I need it to do is when they enter a value in textbox8 (QTY) either 1,2 or 3 the 3 textboxes...
  • Using Large function based on Multiple Criteria
    Hello, I can't seem to get a Large formula to work based on two criteria's. I can easily get a oldest value based one value, but I'm struggling...
  • Can you check my code please
    Hi, Im going round in circles with a Compil Error End With Without With Here is the code [CODE=rich] Private Sub...
  • Combining 2 pivot tables into 1 chart
    Hello everyone, My question sounds simple but I do not know the answer. I have 2 pivot tables and 2 charts that go with this. However I want to...