Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 93055
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 10, 20262026-05-10T23:17:03+00:00 2026-05-10T23:17:03+00:00

I’ve been fiddling with ASP.NET MVC since the CTP, and I like a lot

  • 0

I’ve been fiddling with ASP.NET MVC since the CTP, and I like a lot of things they did, but there are things I just don’t get.

For example, I downloaded beta1, and I’m putting together a little personal site/resume/blog with it. Here is a snippet from the ViewSinglePost view:

 <%         // Display the 'Next and Previous' links         if (ViewData.Model.PreviousPost != null || ViewData.Model.NextPost != null)         {             %> <div> <%              if (ViewData.Model.PreviousPost != null)             {                 %> <span style='float: left;'> <%                     Response.Write(Html.ActionLink('<< ' + ViewData.Model.PreviousPost.Subject, 'view', new { id = ViewData.Model.PreviousPost.Id }));                 %> </span> <%             }              if (ViewData.Model.NextPost != null)             {                 %> <span style='float: right;'> <%                     Response.Write(Html.ActionLink(ViewData.Model.NextPost.Subject + ' >>', 'view', new { id = ViewData.Model.NextPost.Id }));                 %> </span> <%             }             %>                    <div style='clear: both;' />                </div> <%         }     %> 

Disgusting! (Also note that the HTML there is temporary placeholder HTML, I’ll make an actual design once the functionality is working).

Am I doing something wrong? Because I spent many dark days in classic ASP, and this tag soup reminds me strongly of it.

Everyone preaches how you can do cleaner HTML. Guess, what? 1% of all people look at the outputted HTML. To me, I don’t care if Webforms messes up my indentation in the rendered HTML, as long as I have code that is easy to maintain…This is not!

So, convert me, a die hard webforms guy, why I should give up my nicely formed ASPX pages for this?

Edit: Bolded the ‘temp Html/css’ line so people would stfu about it.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-10T23:17:04+00:00Added an answer on May 10, 2026 at 11:17 pm

    Compared to Web Forms, MVC is simultaneously a lower-level approach to HTML generation with greater control over the page output and a higher-level, more architecturally-driven approach. Let me capture Web Forms and MVC and show why I think that the comparison favors Web Forms in many situations – as long as you don’t fall into some classic Web Forms traps.

    Web Forms

    In the Web Forms model, your pages correspond directly to the page request from the browser. Thus, if you are directing a user to a list of Books, you’ll likely have a page somewhere called ‘Booklist.aspx’ to which you’ll direct him. In that page, you’ll have to provide everything needed to show that list. This includes code for pulling data, applying any business logic, and displaying the results. If there is any architectural or routing logic affecting the page, you’ll have to code the architectural logic on the page as well. Good Web Forms development usually involves the development of a set of supporting classes in a separate (unit-testable) DLL. These class(es) will handle business logic, data access and architectural/routing decisions.

    MVC

    MVC takes a more ‘architectural’ view of web application development: offering a standardized scaffold upon which to build. It also provides tools for automatically generating model, view and controller classes within the established architecture. For example, in both Ruby on Rails (just ‘Rails’ from here on out) and ASP.NET MVC you’ll always start out with a directory structure that reflects their overall model of web application architecture. To add a view, model and controller, you’ll use a command like Rails’s ‘Rails script/generate scaffold {modelname}’ (ASP.NET MVC offers similar commands in the IDE). In the resulting controller class, there will be methods (‘Actions’) for Index (show list), Show, New and Edit and Destroy (at least in Rails, MVC is similar). By default, these ‘Get’ Actions just bundle up the Model and route to a corresponding view/html file in the ‘View/{modelname}’ directory (note that there are also Create, Update and Destroy actions that handle a ‘Post’ and route back to Index or Show).

    The layout of directories and files is significant in MVC. For example, in ASP.NET MVC, the Index method for a ‘Book’ object will likely just have one line: ‘Return View();’ Through the magic of MVC, this will send the Book model to the ‘/View/Books/Index.aspx’ page where you’ll find code to display Books. Rails’s approach is similar although the logic is a bit more explicit and less ‘magic.’ A View page in an MVC app is usually simpler than a Web Forms page because they don’t have to worry as much about routing, business logic or data handling.

    Comparison

    The advantages of MVC revolve around a clean separation of concerns and a cleaner, more HTML/CSS/AJAX/Javascript-centric model for producing your output. This enhances testability, provides a more standardized design and opens the door to a more ‘Web 2.0’ type of web site.

    However, there are some significant drawbacks as well.

    First, while it is easy to get a demo site going, the overall architectural model has a significant learning curve. When they say ‘Convention Over Configuration’ it sounds good – until you realize that you have a book’s-worth of convention to learn. Furthermore, it is often a bit maddening to figure out what is going on because you are relying on magic rather than explicit calls. For example, that ‘Return View();’ call above? The exact same call can be found in other Actions but they go to different places. If you understand the MVC convention then you know why this is done. However, it certainly doesn’t qualify as an example of good naming or easily understandable code and it is much harder for new developers to pick up than Web Forms (this isn’t just opinion: I had a summer intern learn Web Forms last year and MVC this year and the differences in productivity were pronounced – in favor of Web Forms). BTW, Rails is a bit better in this regard although Ruby on Rails features dynamically-named methods that take some serious getting-used-to as well.

    Second, MVC implicitly assumes that you are building a classic CRUD-style web site. The architectural decisions and especially the code generators are all built to support this type of web application. If you are building a CRUD application and want to adopt a proven architecture (or simply dislike architecture design), then you should probably consider MVC. However, if you’ll be doing more than CRUD and/or you are reasonably competent with architecture then MVC may feel like a straightjacket until you really master the underlying routing model (which is considerably more complex than simply routing in a WebForms app). Even then, I’ve felt like I was always fighting the model and worried about unexpected outcomes.

    Third, if you don’t care for Linq (either because you are afraid that Linq-to-SQL is going to disappear or because you find Linq-to-Entities laughably over-produced and under powered) then you also don’t want to walk this path since ASP.NET MVC scaffolding tools are build around Linq (this was the killer for me). Rails’s data model is also quite clumsy compared to what you can achieve if you are experienced in SQL (and especially if you are well-versed in TSQL and stored procedures!).

    Fourth, MVC proponents often point out that MVC views are closer in spirit to the HTML/CSS/AJAX model of the web. For example, ‘HTML Helpers’ – the little code calls in your vew page that swap in content and place it into HTML controls – are much easier to integrate with Javascript than Web Forms controls. However, ASP.NET 4.0 introduces the ability to name your controls and thus largely eliminates this advantage.

    Fifth, MVC purists often deride Viewstate. In some cases, they are right to do so. However, Viewstate can also be a great tool and a boon to productivity. By way of comparison, handling Viewstate is much easier than trying to integrate third-party web controls in an MVC app. While control integration may get easier for MVC, all of the current efforts that I’ve seen suffer from the need to build (somewhat grody) code to link these controls back to the view’s Controller class (that is – to work around the MVC model).

    Conclusions

    I like MVC development in many ways (although I prefer Rails to ASP.NET MVC by a long shot). I also think that it is important that we don’t fall into the trap of thinking that ASP.NET MVC is an ‘anti-pattern’ of ASP.NET Web Forms. They are different but not completely alien and certainly there is room for both.

    However, I prefer Web Forms development because, for most tasks, it is simply easier to get things done (the exception being generation of a set of CRUD forms). MVC also seems to suffer, to some extent, from an excess of theory. Indeed, look at the many questions asked here on SO by people who know page-oriented ASP.NET but who are trying MVC. Without exception, there is much gnashing of teeth as developers find that they can’t do basic tasks without jumping through hoops or enduring a huge learning curve. This is what makes Web Forms superior to MVC in my book: MVC makes you pay a real world price in order to gain a bit more testability or, worse yet, to simply be seen as cool because you are using the latest technology.

    Update: I’ve been criticized heavily in the comments section – some of it quite fair. Thus, I have spent several months learning Rails and ASP.NET MVC just to make sure I wasn’t really missing out on the next big thing! Of course, it also helps ensure that I provide a balanced and appropriate response to the question. You should know that the above response is a major rewrite of my initial answer in case the comments seem out of synch.

    While I was looking more closely into MVC I thought, for a little while, that I’d end up with a major mea culpa. In the end I concluded that, while I think we need to spend a lot more energy on Web Forms architecture and testability, MVC really doesn’t answer the call for me. So, a hearty ‘thank you’ to the folks that provided intelligent critiques of my initial answer.

    As to those who saw this as a religious battle and who relentlessly engineered downvote floods, I don’t understand why you bother (20+ down-votes within seconds of one another on multiple occasions is certainly not normal). If you are reading this answer and wondering if there is something truly ‘wrong’ about my answer given that the score is far lower than some of the other answers, rest assured that it says more about a few people who disagree than the general sense of the community (overall, this one has been upvoted well over 100 times).

    The fact is that many developers don’t care for MVC and, indeed, this is not a minority view (even within MS as the blogs seem to indicate).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 66k
  • Answers 66k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • added an answer It's good for situations where you don't have access to… May 11, 2026 at 11:31 am
  • added an answer That information isn't enough to get you a stack trace,… May 11, 2026 at 11:31 am
  • added an answer I'd rather spend a couple of grand and run TFS,… May 11, 2026 at 11:31 am

Related Questions

I keep getting tasks that are above my skill level. How can I address this without coming accross as grossly incompetent?
I have a web-service that I will be deploying to dev, staging and production.
I'm thinking of starting a wiki, probably on a low cost LAMP hosting account.
I have the following tables in my database that have a many-to-many relationship, which
I'm using the RESTful authentication Rails plugin for an app I'm developing. I'm having
I recently printed out Jeff Atwood's Understanding The Hardware blog post and plan on
I find that getting Unicode support in my cross-platform apps a real pain in
I would like to test a string containing a path to a file for
I'm getting this problem: PHP Warning: mail() [function.mail]: SMTP server response: 550 5.7.1 Unable
I'm an Information Architect and JavaScript developer by trade nowadays, but recently I've been

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.