I have the following request:
I must check if a string (for example a name like “Aysegül Özdemir-Aly”) have a special character (like “ä”, “Ä”, “ö”, “Ö”, “ü”, “Ü”, “ß” or “-”, … ).
The title of your thread doesn’t describe the problem - it seems to be about a particular way of solving it, which I don’t recommend.
The check can be implemented in a much more efficient way with the help of regular expressions. In AX, you can use the match() function for that. And if you needed more complex handling of regular expressions, you could call related .NET libraries through .NET Interop.