So, I'm trying to create a random 15 digit password with certain criteria. At least 3 of the following; uppercase, lowercase, special characters, numbers. I also want to make each character unique, I have 2 formulas:
1. =CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))
This creates a random PW all unique, but does not stick to the criteria all the time
2. =CHAR(RANDBETWEEN(65,90))&CHAR(RANDBETWEEN(97,122))&CHAR(RANDBETWEEN(97,122))&CHAR(RANDBETWEEN(97,122))&CHAR(RANDBETWEEN(65,90))&CHAR(RANDBETWEEN(65,90))&CHAR(RANDBETWEEN(42,43))&CHAR(RANDBETWEEN(42,43))&CHAR(RANDBETWEEN(42,43))&RANDBETWEEN(100000,999999)
This 1 sticks to my criteria but creates repeat characters, and is ALWAYS formatted "Uppercase, Lowercase, Lowercase, Lowercase, Uppercase, Uppercase, Special Character, Special Character, Special Character, and then 6 numbers, or however I arrange the formula.
Basically if I could modify the 1st formula to always have at least 3 of each character, but not always in the same order with no repeats! I'm also open to VBA code; although, I am a noob at that!
1. =CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))&CHAR(RANDBETWEEN(33,122))
This creates a random PW all unique, but does not stick to the criteria all the time
2. =CHAR(RANDBETWEEN(65,90))&CHAR(RANDBETWEEN(97,122))&CHAR(RANDBETWEEN(97,122))&CHAR(RANDBETWEEN(97,122))&CHAR(RANDBETWEEN(65,90))&CHAR(RANDBETWEEN(65,90))&CHAR(RANDBETWEEN(42,43))&CHAR(RANDBETWEEN(42,43))&CHAR(RANDBETWEEN(42,43))&RANDBETWEEN(100000,999999)
This 1 sticks to my criteria but creates repeat characters, and is ALWAYS formatted "Uppercase, Lowercase, Lowercase, Lowercase, Uppercase, Uppercase, Special Character, Special Character, Special Character, and then 6 numbers, or however I arrange the formula.
Basically if I could modify the 1st formula to always have at least 3 of each character, but not always in the same order with no repeats! I'm also open to VBA code; although, I am a noob at that!
Last edited: