Amy,
=VLOOKUP(lookup-values,INDIRECT(F4&"!"&"$A$2:$B$200"),2,0)
will do the job.
I assume (actually suppose) that all of your montly sheets are structured in the same way. That is, department and ISF values are all in the same columns across all sheets. Insert that range in the above formula.
If you don't want to see #N/A values, use
=IF(COUNTIF(INDIRECT(F4&"!"&"$A$2:$B$200"),lookup-value), VLOOKUP(lookup-values,INDIRECT(F4&"!"&"$A$2:$B$200"),2,0),"")
Aladin
It did not work. I entered the range which is A2:A)145. And I entered the lookup value- "Department" from the first column. The TSF values are always in column #23 or column W, so I entered 23 as the column_num argument.
This is what I came up with:
=IF(COUNTIF(INDIRECT(F4&"!"&"$A$2:$AO$145"),Department), VLOOKUP(Department,INDIRECT(F4&"!"&"$A$2:$AO$145"),23,0),"")
It returns a blank box at this time. I am sure I am missing something fundamental.
Department must be a value like or refer to a value.
Put the department you're interested in, say, Accounting, directly in the formula between double quotes, that is,
=IF(COUNTIF(INDIRECT(F4&"!"&"$A$2:$AO$145"),"Accounting"), VLOOKUP("Accounting",INDIRECT(F4&"!"&"$A$2:$AO$145"),23,0),"")
Or enter the department of interest in some cell, say, in G4 and use this in the formula:
=IF(COUNTIF(INDIRECT(F4&"!"&"$A$2:$AO$145"),G4), VLOOKUP(G4,INDIRECT(F4&"!"&"$A$2:$AO$145"),23,0),"")
Aladin