Hi,
I need to perform a function if the value exists witin a predefined range. In matlab you'd probably use ANY but I cannot find an equivalent in excel.
Any help or suggestions will be greatly appreciated!
Many thanks,
Bond002
Hi,
I need to perform a function if the value exists witin a predefined range. In matlab you'd probably use ANY but I cannot find an equivalent in excel.
Any help or suggestions will be greatly appreciated!
Many thanks,
Bond002
Last edited by bond002; 11-17-2011 at 12:06 PM.
something like?
=IF(COUNTIF(A2:A11,B2),your_formula,"")
Where there is a will there are many ways.
If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner
Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.
Having reread the question - I have not given a solution that would work.
See NVBC above
edvwvw
Last edited by edvwvw; 11-17-2011 at 11:54 AM.
Thanks guys.
It's not that simple and I guess I should've been a bit clearer.
NBVC: I tried the countif but it performs a true function regardless of the value existing or not exisiting within the range.
edvwvw: The range of values is much bigger than the one in the example and it consits of different values (not necessarilly between 1 and 10 only). It could be, say 1,3,4,5,7,10,12 etc.
Any ideas how to solve this?
Cheers,
Bond002
My formula is in C2.
Change your number in B2 to 2, for example and see the result in C2.
Works as a charm. Thank you!
I have no idea why it didn't work when I tried this the first time. Must have made a typo in the formula.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks