0

We currently have .net 3.5 using web form with code behind pages. Is it possible to add MVC functionality to this project to any existing pages?

What about new pages added to the project?

I assume the answer is no but maybe there is some creative ways out there.

Secondly. Do I have to do anything special to use Razor on these web form pages or does it come in the box with .net 3.5 +?

2
  • 1
    Here and here and of cource here Commented Oct 31, 2013 at 16:12
  • @Ramunas thank you, I didn't think it was possible! :) Commented Oct 31, 2013 at 16:30

1 Answer 1

2

ASP.NET MVC and ASP.NET web forms will run side by side. You can then add new pages, either MVC views, or web forms, to the project. The linking is a bit different between the two, as the MVC will use friendly URLs out of the box and the web forms will not. You can use routing to link to web forms, as well, but be sure you are using a different enough routing you don't accidentally end up with both a web forms endpoint and an MVC view with the same route.

I dont' believe Razor works with .NET 3.5, but have not played with the idea to see if there is a way. I would personally consider determining if you can update, as there are benefits to 4.0 (and now 4.5, although it is better to use with Visual Studio 2013, which is not yet in wide release - RTM on MSDN).

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

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.