A lot of release notes for Visual Studio 2012 talk about .NET 4.5 and MVC4, but I can't tell if MVC4 is actually part of the .NET 4.5 release. Anybody know for sure? I would love not to have to install MVC separately on my server.
No, ASP.NET MVC 4 is baked into VS2012, exactly the same way ASP.NET MVC 3 was baked into VS2010 but not part of .NET 4.0 (there was a separate download that you could install on your servers). But there will also be a separate download of ASP.NET MVC 4 for VS2010 SP1 in which you obviously won't be able to use the .NET 4.5 specific features, such as async/await, but you will still be able to develop an ASP.NET MVC 4 application and target .NET 4.0.
ASP.NET MVC has made a point of NOT being tied to a particular .NET incarnation. That way, you can use the latest and greatest irrespective of what .NET version your hosting provider uses.
If the provider supports ASP.NET, that's all you need to know.
For this precise purpose, ASP.NET MVC is bin-deployable, meaning you can deploy the MVC dlls yourself, along your application - without requiring special rights from the hosting provider.
Phil Haack has a great article describing how to bin-deploy MVC3. There's even tooling support in VS for this scenario!
I assume the workflow for newer MVC incarnations is similar.
Related
I have an existing old WebForms application.
I need to add an MVC project.
The server where it is hosted is Windows 2003 R2, so only .Net 4 can be used.
And we use VS 2017.
I tried to add the project, but there is only "Empty" option available, and the "MVC" checkbox below is disabled, as well as "Web Forms" and "Web API".
Could you please tell how I can add an MVC project?
Presumably you need to download the ASP.NET MVC 4 installer.
The bigger question is, why not spin up an additional webserver which can support newer versions of .net?
We have an ASP.Net MVC 1.0 solution developed using Visual Studio 2008 and .net Framework 3.5SP1.
We would now like to upgrade Visual Studio to 2010.
If we just open the solution in VS 2010 and do not change the framework version, can we just continue to develop as before?
If we open the solution in VS 2010 and change the framework version to 4.0, will we automatically start using ASP.Net MVC 2.0, or will it continue to use ASP.Net MVC 1.0?
Is there anything we need to take into consideration when upgrading to ASP.Net MVC 2.0?
Thanks
Shiraz
Yes.
I don't know if this is supported, but I wouldn't go there. It would make more sense to update to MVC 2 first, then .NET 4.
Yes, lots. Look at the release notes on CodePlex. Many things have changed, including model binding, TempData handling, and the return types of HTML helpers. These are breaking changes. There's a wizard which tries to help, but you're going to have to fix some of this manually.
It will continue using ASP.NET 1.0 unless you run the tool to upgrade to 2.0. If I am not mistaken, all the tool does is update your web.config to point all MVC references to 2.0 instead of 1.0
My question is very simple. Can I run an ASP.NET MVC application on shared servers that has installed ASP.NET 3.5 but not MVC?
If this is possible could you tell me how?
You just need to include System.Web.dll in the bin folder and it should work fine (and maybe in the dll folder for routing. I'll check out for exact article for this in a moment).
Here's a link with proper a TODO.
Most interesting part:
With the release of ASP.NET MVC Beta, the assemblies distributed with ASP.NET MVC are automatically installed into the GAC.
System.Web.Mvc
System.Web.Routing
System.Web.Abstractions
While developing an application locally, this isn’t a problem. But when you are ready to deploy your application to a hosting provider, this might well be a problem if the hoster does not have the ASP.NET MVC assemblies installed in the GAC.
Fortunately, ASP.NET MVC is still bin-deployable. If your hosting provider has ASP.NET 3.5 SP1 installed, then you’ll only need to include the MVC DLL. If your hosting provider is still on ASP.NET 3.5, then you’ll need to deploy all three. It turns out that it’s really easy to do so.
I am thinking about creating my new asp.net mvc web application compatible with native ms .net as well as mono (ms server licensing cost compared to linux server licensing cost).
DB access was handled by NHibernate.
Is it possible? What are the limitations of mono regarding asp.net web applications?
Would like to hear about asp.net mvc on mono too.
Thanks
I have built a "sandbox" site in ASP.NET MVC compatible with MS/Mono.
Routing was my main concern and it seemed to be just fine under Mono.
I have not used NHibernate undr mono so no answer for you there unfortunately.
If you get the latest version of MonoDevelop (just ported to windows recently.) you can fire it up really quickly and see if your existing app is compatible.
Kindness,
Dan
You can use NHibernate on mono, it wokrs without any problems in my experience.
My IT folks don't like to install software on their precious servers unless they must. To that extent, does the server that serves my ASP.NET MVC application need to have the MVC 1.0 Framework on it in addition to .NET 3.5 sp 1 Framework?
Nope. You can deploy the System.Web.Mvc.dll to your application's bin directory if MVC has not been installed on the server. The only requirement is that the server have .NET Framework 3.5 (preferably with SP1)
Phil Haack put together an article on bin deploying MVC apps here. It mentions the ASP.Net MVC beta drop, but it still works just fine (given the caveat that .Net 3.5's installed).