views:

188

answers:

1

Hi All,

I enabled a routing on ASP.NET web application running IIS 6.0 using

RouteTable.Routes.MapPageRoute("Simple", "{testvalue}", "~/Test.aspx"); in Global.aspx.cs

This works fine when I use http://www.MyDomain.com/Hello, however when I use http://subdomain.mydomain.com instead of loading the configured default page (default.aspx), it tries to route the request and sending to login.aspx page as we use Forms Authentication.

Any suggestions on how to enable routing at root directory?.

A: 

If you have Default.aspx on the root of your application. Thus, Set the RouteTable.Routes.RouteExistingFiles to false.

Mehdi Golchin
Thanks for your suggestion, it didn't help but I was able to fix the issue and posted my approach to solution above.
Vijay Rayapati
Sorry for that, glad to fix it.
Mehdi Golchin