views:

162

answers:

1

Hi!

On the project I'm working, it previous version was build on ASP.NET classic (aspx) and now this very same project is build on ASP.NET MVC.

But, some users may still call the older pages (for example, an user add the old page to his favorites) and when this happens MVC throws an error.

How can I identify if an aspx page is being called? I tried to debug the Home Action method but the application didn't hit there.

Thanks!!

+1  A: 

Given that these pages would actually exist in the directory which maps to their url, using this setting in the global.asax should help:

routes.RouteExistingFiles = true;

The default for this setting is false. For more information on hybrid websites, please look here.

Dan Atkinson