tieing a set random item to other random name

wolf735

Board Regular
Joined
Oct 4, 2009
Messages
52
Office Version
  1. 365
Platform
  1. Windows
hello im creating a charter sheet for a game i play. im trying to get a randomly chosen name to appear based on gender of character. the two formals work by themsself but im having trouble getting the names to correspond to gender.

gender is =INDEX($E$5:$E$6,RANDBETWEEN(1,2)) e5 male
e6 female

for the name =IF(K10=1,INDEX('master names'!$B$2:$B$1355,RANDBETWEEN(1,1354)),INDEX('master names'!$C$2:$C$4383,RANDBETWEEN(1,4382)))

problem is in the logic test, playing around using 0 and 1 it works. if i say k10=male and k10 is male im getting female names.


thank you for help.
 

Excel Facts

Repeat Last Command
Pressing F4 adds dollar signs when editing a formula. When not editing, F4 repeats last command.

MisterBate5

Board Regular
Joined
Jan 2, 2011
Messages
240
If you formula in the cell choosing the name, does the following work as repalcement for the start of the formula?
Code:
=IF($K$10="male",INDEX(...
 
Upvote 0

Forum statistics

Threads
1,191,684
Messages
5,987,994
Members
440,124
Latest member
dippy_egg

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top