I am having trouble creating a regular expression to disallow the following four characters and limit the size:

/
#
?
\

What I currently have is:

```
Regex regex = new Regex("^[^/\\#?]{0,1024}$", RegexOptions.Compiled);
if (!regex.IsMatch("\\"))
{
    Console.WriteLine("Bad");
}

```

All of the characters except \ are disallowed. I cannot get \ to work.

Any suggestions on how to support this?