Running ASP.NET MVC 3 application on a box with beta installed - how can I remove System.Web.Mvc from the GAC after installing ASP.NET MVC beta?

I have an application built against MVC Preview 3 (link to local copies of MVC assemblies) that I am trying to modify / test on a machine with ASP.NET MVC beta installed. I'm not interested in updating this app to work with the MVC beta - I just need to make a few small changes.

It doesn't work with MissingMethodExceptions on RouteCollection.IgnoreRoutes (in global.asax.cs) because at runtime the CLR always finds the beta version of System.Web.Mvc in the GAC and loads that instead of the preview version in my site \ bin directory.

Since the assemblies have the same name, version and public key, I believe there is no way to differentiate between them in the web.config, so I think the only solution here is to remove the ASP.NET MVC beta assemblies from the GAC.

Only - I can't do this because they are installed by the Windows installer, so I can't uninstall them with gacutil.exe / u and I get Access Denied when I try to uninstall them directly.

Does anyone know how I can remove this assembly - or, otherwise, how to start / host an application that needs System.Web.Mvc 3 preview on a system with System.Web.Mvc beta in the GAC?


source to share

4 answers

You can download ASP.NET MVC Preview 3 Source and compile it with your own SNK or give it another version as official and link to your site.



I think your best bet, since the app was built in pre-release, is to update the app to work with the beta, knowing that you will eventually have to update it to work with the production release. I know this is not what you want to hear, but I think this is a fact of life with CTP releases and public beta releases.



It looks like Hangy's answer is in line with the bill - if we end up supporting this application across multiple workstations, that's exactly what we'll do until we can translate the code into beta. / P> Still, nevertheless less, what I actually did was hack the registry so I could remove System.Web.Mvc from the GAC - the full details are posted on my blog . The existing code is now running without any changes in the Preview 3 or Beta projects.



According to this question here and this link link you need to delete the registry key






// Edit - Oh what your blog lol. Thank you for message: -)



All Articles