This is related to my question on how to handle errors from jQuery AJAX calls. Several responses suggested that I use the \"error\" callback to display any errors from a jQ
If you're using
[HandleError]
then throwing a HttpException is going to get caught and routed to your custom error page.
Another option is to use
Response.StatusCode = 500;
Response.Write("Error Message");
Response.End();
There's probably a more convenient way to write this but I haven't stumbled upon it yet.