1

How to add an ASP.NET MVC project to an existing ASP.NET Web forms application. How to call MVC project page from existing website.

2 Answers 2

0

You can refer this step-by-step guide on how to do that.

Your question is similar to

Is it possible to host an asp.net MVC in the same folder as asp.net web forms app?

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

Comments

0

We were in the exact same situation as you and it's not as bad as you might think. Thanks to Nuget it's a fairly easy process that you can follow and Dave Paquette describes how to do it in his blog post

And once you've got Mvc up and running all you need to do to go from one to the other is to redirect to Mvc from webforms:

Response.Redirect("~/Controller/Action/")

You can also use the Mvc routing system to generate routes from within webforms as well:

System.Web.Mvc.UrlHelper url = new System.Web.Mvc.UrlHelper(HttpContexxt.Current.Request.requestContext)
Response.Redirect(url.Action("Action", "Controller"))

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.