fishoutofwater
New Member
- Joined
- Jul 20, 2011
- Messages
- 38
I have a range A1:D40. There are all kinds of pieces of data in the range including: #n/a, 0, ....
In E1, I want to pick something random from the range, as long as it meets these criterion:
(1) LEN(ofpick)>5
(2) ISERROR(ofpick)= False
In other words if I have this:
A...................B.....................C
RiceMeal..........0....................#N/A
Oatmeal..........OhNo...............#N/A
Pumpkins.........#N/A...............Ice
#N/A..............Kittens.............Dog
#N/A..............22...................0
0...................Happiness.........BigMac
Soda..............Sunshine..........Sledding
I want to have some sort of command that looks like this:
RAND(A1:C7) IF cell has text lenght > 5
So, I'd want E1 to give me something random from:
RiceMeal
Oatmeal
Pumpkins
Happiness
Sunshine
BigMac
Sledding
since every other entry in the range is either too shart LEN or Is an #N/A error.
Is this possible?
ps. For some reason I only have RAND with my version of excel, so another constraint here is that I cannot use RANDBETWEEN
In E1, I want to pick something random from the range, as long as it meets these criterion:
(1) LEN(ofpick)>5
(2) ISERROR(ofpick)= False
In other words if I have this:
A...................B.....................C
RiceMeal..........0....................#N/A
Oatmeal..........OhNo...............#N/A
Pumpkins.........#N/A...............Ice
#N/A..............Kittens.............Dog
#N/A..............22...................0
0...................Happiness.........BigMac
Soda..............Sunshine..........Sledding
I want to have some sort of command that looks like this:
RAND(A1:C7) IF cell has text lenght > 5
So, I'd want E1 to give me something random from:
RiceMeal
Oatmeal
Pumpkins
Happiness
Sunshine
BigMac
Sledding
since every other entry in the range is either too shart LEN or Is an #N/A error.
Is this possible?
ps. For some reason I only have RAND with my version of excel, so another constraint here is that I cannot use RANDBETWEEN