I'm very new to learning RegEx, and need a little help updating what I have. I will use it to evaluate student spreadsheet functions. I know it isn't perfect, but I'm trying to use this as a stepping stone to a better understanding of RegEx. I currently have [DE45\\+\\s]*$ but it does not validate for criteria #4 below. Any help is greatly appreciated.
I need to validate an input so that it matches these four criteria:
- Letters D and E: (UPPERCASE, in any order, in any length string)
- Numbers 4 and 5: (in any order, in any length string) Special
- Characters: comma (,) and plus (+) (in any order, in any length string)
- All six characters
DE45+,must be present in the string at least once.
Results
- pass: =if(D5>0,E4+D5,0)
- pass: =if(D5>0,D5+E4,0)
- fail: Dad Eats @ 05:40
- pass: Dad, Eats+Drinks @ 05:40
- fail: =if(E4+D5)
- pass: DE45+,