Regular for \have to contain\"

  • 28 March 2017
  • 9 replies
  • 0 views

Badge +3

Hi there!

I tried to use

nicht(enthält(",")

as definied regular to give an error massage when field does not contain a ,

What do I wroing?

For translation NICHT means not an ENTHÄLT means contain.

THANKS!!!

Best wishes,

Jakob


9 replies

Badge +9
The function 'contains' expects two parameters.
Returns TRUE where string contains the element.
contains(string, element)
This expression works as expected: not(contains({Self},","))
Userlevel 4
Badge +12

Yes, the field name is missing. If you need to check the current field to contain a "," you can use the self operator

nicht(enthält({Self}, ","))

If you need to check another field (or if you want to name the field instead of using self operator, you can just use the field to check by grabbing it from the collection of named controls / "Benannte Steuerelemente"

nicht(enthält(Feldname, ","))

Badge +3

Hi there!

Thanks for the swift answers.

I tried the mentioned solution an made screenshot because unfortunately it doesn't work.

What do I wrong?

THANKS!!!
Jakob

PS: The pictures above you find in a bigger format also at Dropbox - mustermann.pdf 

THANKS!!!

Badge +8

Strange. I can reproduce your issue but have no time for it now to investigate it more. To be continued...

Badge +8

The following seems to work (control settings):

I still do not know why the not(contains(...,...) does not work. It works perfectly with a semi-colon.

Badge +10

It is working for me 

not(contains(Title,","))
 which version is your form
Badge +8

Hi Jakob Putz‌,

Ok. I must have been not that clear yesterday confused.png not(contains({Self}, ",")) works indeed as expected.

What I noticed, is that your {Self} is not red. You probably typed it instead of selecting it from 'Named Controls'. This is probably your issue.

Cheers,

Rick

Badge +3

Thsnks!

When I try to force user to enter information like

Mustermann, Max

and want to avoid entries like

Mustermann Max

which regex should I use

I tried it with

[,]s+

but does not work...

Thanks!!!

Badge +9

Hi Jakob,

for first question please mark the answer that helped You as correct and create a new entry in forum for a new question.

Kind regards

Manfred

Reply