0

This question is coming from a Front-End developer new to .NET.

I'm working on a web app that was built a while ago using Webforms. I was asked to integrate two new features to this application. The features would be accessible via two new tabs added to the navigation bar.

What I want to happen is, when the user clicks on the new tab, the application loads up the MVC project as a view inside of the Web Forms app. Here's a link to a picture to explain it better:

enter image description here

The way the project was originally setup is we have the original Webforms project, and we created an MVC project which are siblings inside the same parent folder. The backend devs think this will work fine for them. I have no idea how to get the two projects to load up simultaneously. There hasn't been much work done on either side yet so we're open to ideas of how to restructure this.

I should also add that for the new features the Back-end is just serving up JSON, and I will use AngularJS on the Front-End as opposed to Razor.

Other potentially relevant project info: Using Visual Studio 2012 (I think we have access to 2013 however) .NET MVC 4 Webforms (2.0 or 3.5 possibly)

Andrea
  • 11,801
  • 17
  • 65
  • 72
Mike Fisher
  • 913
  • 3
  • 13
  • 27
  • I notice you mentioned "when the user clicks on the new tab, the application loads up the MVC project as a view...". I am currently running a site that was originally a web application project using web forms, but now has MVC capability in the SAME project. The two can work nicely together, you just have to get the right set of references and tweak the MVC routing engine to ignore aspx requests. See this article by Scott Hanselman: http://www.hanselman.com/blog/IntegratingASPNETMVC3IntoExistingUpgradedASPNET4WebFormsApplications.aspx. – macoms01 Mar 07 '14 at 18:55
  • There are obviously many more things to take into consideration, but I deployed the site last month with no issues. It was not an easy task and will be especially difficult if you are new to .NET, but there are many articles out there explaining how to do this. Search Google for "MVC webforms hybrid" and you will find hundreds of links. See this stackoverflow question as it is probably a duplicate (unless you are set on having seperate webform/mvc projects): http://stackoverflow.com/questions/7288840/asp-net-mvc-alongside-web-forms-in-the-same-web-app. – macoms01 Mar 07 '14 at 18:58
  • Yeah I've seen a few articles including the Hanselman one before. I've also heard about One ASP.net and wondering if that's a better solution (which is why I mentioned I'm on VS2012 but could go to 2013 with One ASP.net I found this article: http://www.c-sharpcorner.com/UploadFile/4b0136/perform-operations-on-webforms-from-mvc/ but it seemed geared towards creating a new project webforms as opposed to upgrading a large legacy project. Another area of confusion is most articles where they're talking about .NET MVC they are using Razor syntax as opposed to Angular. (Don't see as a big issue) – Mike Fisher Mar 07 '14 at 19:56

0 Answers0