I'm trying to calculate a result based on if a period is weekly or monthly then look up the relevant value in an array based on the weekly or monthly equiv as follows
=IF(R21="weekly",VLOOKUP(Q21,$AG$2:$AL$15,3)*OR(R21="monthly",VLOOKUP(Q21,$AG$2:$AL$15,4)))
As the cell R21 happens to be monthly, the result from the array (AG2:AL15) should be 10 however the formula is looking for weekly first therefore returns FALSE rather than continuing through to the OR statement.
Can anyone please advise the correct syntax for this? Note the lookup function is referring to different columns within the array dependent on whether cell R21 contains "weekly" or "monthly"
Thanks
Bookmarks