Getting #REF! on using indirect function

nachiketdp

Board Regular
Joined
Jan 31, 2007
Messages
53
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.
 

venkat1926

Well-known Member
Joined
Aug 21, 2005
Messages
4,824
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.
 

nachiketdp

Board Regular
Joined
Jan 31, 2007
Messages
53
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 !!

Regards,
Nachiket Pendharkar.
 

Forum statistics

Threads
1,085,311
Messages
5,382,901
Members
401,808
Latest member
huyennhiteen9xx

Some videos you may like

This Week's Hot Topics

Top