Strange Excel Validator behavior

43 Views Asked by At

I meet strange Excel validator behavoir. My goal is to forbid user to enter some special symbols like '*'. so i found a solution based on ROW and INDIRECT.

then when i`m trying to test - it woks only after manual access to Data Validation dialog!:

  1. execute script, click button - puts excel validators
  2. try to enter in A1: 'aa*' - allowed
  3. put 'aa' to A1
  4. open 'data validation' dialog for A1 to check if everything is correct
  5. click OK (nothing changed)
  6. try to enter in A1: 'aa*' - forbidden with Validator!

so, the expected behavior appears only after manual accessing the data validation dialog maybe something wrong with my code?

the example is gis also checks is valu is unique in the given range and checks value length. ~ symbol is added because of SEARCH command

https://gist.github.com/ASamSam/23e0a8be95582ab66322cbebb11f30f9

Same behavior in excel online and classic one

0

There are 0 best solutions below