I wonder if someone could help me, I am using a VLOOKUP function to find a number / value in a pivot table and return that value in the cell. However I want it to return 0 (zero) if there is no number / value in the table.
I have in the past used COUNTIF function and it has worked but now it keeps giving me a #VALUE! - i have tried changing the formats so that all text is TEXT and all numbers are NUMBERS etc. but this doesnt seem to correct the problem.
I think it is something simple but for the life of me cant work out what it is!!
This is the formula I am using, column A is a code (in TEXT) and B is a total in stock.
=IF(COUNTIF(Pivot!$A$1:$B$5,A1),VLOOKUP(Pivot!$A$1:$B$5,A1,2,FALSE),0)
I would appreciate any help.
Thanks in advance
Neil
Bookmarks