Well as an initial c# Winform developer I’ve extend my knowledge to Webforms and started to create lots of web application using that. Most of the applications are involved in the insurance price comparison and connectivity.
I’ve masterd the client and server side with lots of server infrastracture and DB, and client html css and javascript.
After the 2008 stock crises we got a very big project that was suppose to lift us back into game. the R&D manager decided to start doint it with MVC and jQuery with combination of Linq. As the senior developer I’ve first opposed since all of our infra is in webforms.
And if it works in a good manner why touch it. Well you don’t need to be the “brightest bulb in the tanning bed” to read the title and figure that we decided to use MVC. The reason is that as a developer in a highway of tech you allways have to stay put and lern the latest tech. And that what developers need to do to stay with the fingers on the pulse.
Well we start learning an writing ‘Hello MVC’ tutorials, we comined that with ‘Hello Jquery’ and ‘Hello LINQ’. The first barrier we had encounter was that we had to change our base perception. We have also decided not to use session! the big advantage is to allow load ballance without sticky session. MVC don’t have all the overweight Webform have it doesn’t use ViewState that can overweight pages most of the time without any purpose. And using Ajax in Webform just… how do I say it in an unoffensive manner…. other that SUCK!
The ajax tool kit is doing a really bad job specially the update panel that is not really ajax.. because if wont allow you to send a string but you have to send the entire form with viewstate and all other overhead that are really redundant in an ajax call.
In MVC the concept is that we split the application in to 2 main modules. The Controller and the View.
The Controller is the logic unit, it can use other logic Dll’s and decide what is the content that we need to use in a certain view.
Than it packs it all in a Model object, that is similar to a struct of properties. that view is getting that package (Model) and it uses to show it. so the View is only the UI if it has logic that have to be UI logic!
The Jquery is a plesure. After working with javascript alot I’ve found that you can do amazing client logic in couple of lines.
When programing jquery I play a game.. I’m tring to create the shortest script I can. single line is always the jackpot :)
MVC is very comfortable in receiving ajax calls, you can easly add authorize logic to controllers and actions. its a big advantage to differ between Get logic and Post in the server to allow same action in an initial call and postbacks. There was one issue that made me feel bad… The notorious “SPAGHETTY CODE”, it felt like after the revolution of webforms, where the server side logic and the aspx were seperated, MVC took us back in time. First, when I used the spaghetty code I told to my self silently “Its only UI.. Its only UI…” to make my self feel better. but after some time I really started to feel like Its only UI! and I’ve notice it’s true. If we have a full seperation on logic and UI. the UI can have nasty spaghetty code. and thats more easy to maintain because its UI. So I really started to like the concept. In Webforms UI bug can be found in the easy case in the aspx and in the hard case some where in the Code behind logic (in the hardest it can have to do with JS).
Well, It is going to be really hard to go back into webforms. the easyness of editing and the flexibility just makes web programming really fun!
Lets see if you go back to the [obsolete] Webforms.
