What could cause System.Web.Mvc.UrlHelper is null in ASPX inline code in MVC 3?
UrlHelper url = new UrlHelper(HttpContext.Current.Request.RequestContext);
Thank you for reply.
But I am curious why Url.Content() suddenly not working, and Url object is null in ASPX inline code <% … %>?
I think there are something error in your MVC 3 project. You may create a new project and try again. If it has the same issue, please repair your VS.
Now, even I uninstall and reinstall VS 2010 only have MVC2 in machine, my old project which is in MVC2 also hit the same exception.