Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Last post Oct 20, 2009 01:38 AM by Bob K.
Oct 19, 2009 09:50 PM|LINK
Is there a way to precompile MVC application including code and views for deployment?
I am using MVC and when I try to publish my app, I donot get the dialog options that allow you to precompiles views or make the app not updatable. I also tried to directly use aspnet_compiler command line but I get numerous errors for views.
Any solutions, suggestions is greatly appreciated.
publishing mvc sites
Oct 20, 2009 12:26 AM|LINK
You need to install the Visual Studio Web Deployment add-in (see
In your MVC solution, right click on the MVC project and select "Add Web Deployment Project..."
Oct 20, 2009 01:38 AM|LINK
Thanks for your reply Jacques. I did not get a chance yet to test your solution, although I have a feeling it will work.
I also figured out that running the command line utility using aspnet_compiler will also do the job. The command line is:
(framework directory)\aspnet_compiler -v /virtualDirName outputdirectoryName
Originally when I ran the command line utility I had one file that was not part of vstudio project, which was creating issues. But once that file was taken care of(the file issue wasnot related to the subject of this discussion), the command line worked.