End Google Ads 201810 - BS.net 01 --> Good morning.

I am trying to remove any special characters in a string I pass.

I came across this code:


using System.Text.RegularExpressions;
string = Regex.Replace(string, @"[^\w\.]", "");

It appear to work very well, except it doesn't "filter" out the underscore (_)character for some reason.

I was hoping someone could help me better understand what the @"[^\w\.]", does and how I can add or remove something to filter out the underscore.

Thank you, WHEELS