Fog Creek Software
Discussion Board

Welcome! and rules

Joel on Software

HttpRequestValidationException in ASP.NET

I prefer to handle all of my exceptions and validate all of my input text in my ASP.NET applications. When validating text (via Regular Expressions) it's nice to just deny any attempts to submit maliscious code in input text-boxes.

In my validations I included the < symbol. It is inteded to reject this character. However, when I check this character the page throws an unfriendly full-page error --- including HttpRequestValidationException. However, I was unable to catch the < before this page got it, and the Visual Studio documentation does not contain a reference to this exception. Can you help? Thanx, Dan H

Dan L. Henning
Saturday, February 26, 2005

See the inappropriately named "ValidateRequest" property.

Brad Wilson
Monday, February 28, 2005

*  Recent Topics

*  Fog Creek Home