Example for regular expression to restrict changes by Item Name
![]()
We are using CLM 4.x and I'm searching for an example how to prevent file / folder names that have problems on Unix / Windows systems (blanks / "/" / ...).
I tried a lot of expressions but nothing works fine. Are there any example ? |
Accepted answer
![]()
Evan Hughes (2.4k●13●18)
| answered Nov 26 '14, 10:53 a.m.
JAZZ DEVELOPER edited Nov 26 '14, 11:15 a.m.
I suggest specifying a list of legal characters:
^[_0-9a-zA-Z\.]+$
in the 'Restrict Changes by Item Name' advisor. e.g:
![]()
With that predcondition enabled, I am able to deliver the creation of the file "TestFile.txt" but unable to deliver the creation of "!TestFile.txt".
Katrin Heymann selected this answer as the correct answer
Comments I tried but with the setting "allowed" I am not able to upload a file with the name "TestFile.txt" and with the setting "prevented" every name (including special signs) is allowed.
I've updated the answer to include a screenshot and mention that it properly allows the delivery of a file matching the regex and prevents the delivery of a file that doesn't match the regex. |