Absolute path issue
I have an ActionResult in some controller and i want to return a view from another controller I am doing this:
return View(VirtualPathUtility.ToAbsolute(@"~/Views/Order/Index.aspx"));
I see that page (there is a jqgrid on it) but not fully loaded, jqgrid makes an ajax request to get the data but the request fails, thing which doesn't happen if the absolute path is correct. So, is that开发者_运维问答 the correct way to get the absolute url of a view? because i don't understand why the ajax call fails.
I think You don't need the abs stuff. Does this work?
return View(@"~/Views/Order/Index.aspx");
精彩评论