Is there a windows form textbox or c# string native member method that checks if its contents have any non-alphanumeric character?
or do I have to do it manually?
EDIT: I used @Habib's answer and added so that white spaces are checked as well, and to my surprise, it worked! lol
bool result = strVariable.Any(r=> (!char.IsLetterOrDigit(r) && !char.IsWhiteSpace(r)));
Btw, I've never used the "lambda" expression that's why I'm surprised the code above worked when I added the whitespace condition on @Habib's initial answer.