1

I'm new to ASP.NET MVC3, I got simple work to add a page in already existing web site.

Any changes made in Controller files are not reflected. Even I renamed Controller folder to Controller1 etc.. but site is working perfectly!!! Rally Sucks. But renaming Views and other folders throw errors.

Am I doing anything wrong? Any Helps are very much appreciated!

2 Answers 2

2

Since ASP.NET MVC uses an ASP.NET web application model if you change the code in your controllers you should recompile your project for changes to take effect.

Sign up to request clarification or add additional context in comments.

14 Comments

Thank you for your replay. How recompile my project using Visual Web Developer? or is there any other alternative way to do it?
Do you have a Build -> Build [yourproject] menu?
What is not working? What exactly have you done? What error are you getting? Please provide more details.
All I want to add a page called Map in a MVC3 project. I tried to create controller called MapController.cs and a View. Then I hit build. When I tried to access localhost:2202/Map its showing Server Error in '/' Application. The resource cannot be found.
Did you add an action inside this MapController? Like for example: public ActionResult Index() { return View(); }. Then did you add a corresponding view in the correct location which is ~/Views/Map/Index.cshtml (and not ~/Views/MapController/Index.cshtml)? Does your MapController class inherit from System.Web.Mvc.Controller? Have you modified your routing configuration? If yes, how do they look like? Also you mentioned that you are navigating to http://localhost:2202/Map. In this url you haven't specified an action name. Only the controller. ...
|
0

Make sure you have the latest dll and pdb files loaded in the bin directory on the server for your project.

E. G. [on the server ...] D:\MyProjectFolder\bin\myProject.dll E. G. [on the server ...] D:\MyProjectFolder\bin\myProject.pdb

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.