views:

131

answers:

1

I am having some trouble getting Elmah to work with url routing in an asp.net webforms application. Elmah is mapped to "elmah.aspx" and I have tried a couple of variations on:

routes.Add(new Route("elmah.aspx", new StopRoutingHandler()));

Is there a way I can ignore all .aspx pages?

+1  A: 

UPDATED:

Please look at step 4 on the elmah Google Code page.

To ignore all .aspx files. You just do:

routes.Add(new Route("*\.aspx", new StopRoutingHandler()));

You could also do:

routes.IgnoreRoute("*\.aspx");

Please refer to msdn.

alexn
Combo of this and fixing some web.config stuff cleared it up, thanks
Luke Lowrey