Using ASP.NET AJAX with ASP.NET MVC

Using ASP.NET AJAX with ASP.NET MVC.

I thought you couldn’t use them both, given that a ScriptManager control is server side and implementing it would break the design pattern of MVC Apps…turns out the raw Javascript that is used behind the Microsoft Ajax toolkit is available as a standalone download, and by referencing this on the client side View pages one can actually use all the features of Ajax toolkit without breaking the MVC model as you no longer need to have the server side ScriptManager control present.

CSS: fixed menus vs AJAX AlwaysVisibleControl

So after several days of fruitless research into understanding why my implemented control which utilised the Microsoft AJAX Toolkit’s AlwaysVisibleControl would render on my developer’s box but not my test deployment server, I finally gave up and went back to my roots, opting for use of a pure CSS solution, which led me to a great resource page for CSS: fixed menus

Hopefully there are no ‘bite-me-in-de-arse-at-release-time’ issues with using the ‘standards’ CSS coding approach vs the Microsoft approach of using AJAX Toolkit controls for an IIS hosted solution. This might sound paranoid, but this is exactly what happened to me some time ago when I used pure HTML controls in a web page rather than their ASP.Net control equivalents resulting in some rather irratic rendering behaviors and a good few hours more than I had planned of debugging.

However this experience does reinforce my opinion that a true master of ‘Microsoft web programming’ hasn’t just mastered knowledge of ASP.Net tools alone, but also knows his HTML, CSS and Javascript, to me the traditional ‘standard’ web development arts, well enough to hold his own. That knowledge definitely led me today to an alternative solution to a hindering problem.