-
|
In this tip, I explore one approach to building Ajax applications with ASP.NET MVC. I show how you can use view data when building Ajax applications with ASP.NET MVC in the same way as you would use view data when building server-side application. I demonstrate how to create a custom HTML Helper that renders client view data. One of the primary benefits of building an ASP.NET MVC application is that it enables you to build web applications that support a sharp separation of concerns. This sharp separation of concerns enables you to build applications that are highly testable and highly adaptable to future change. Communication between the different parts of an ASP.NET MVC application is extremely constrained. An MVC view only talks to an MVC...
|
-
|
I've done a series of four podcasts dedicated to JavaScript over the last month. Why? Because of this rockin' sweet announcement: Microsoft is going to make jQuery part of the official dev platform. JQuery will come with Visual Studio in the long term, and in the short term it'll ship with ASP.NET MVC. We'll also ship a version includes Intellisense in Visual Studio. The Announcement Blog Posts ScottGu on the jQuery/Microsoft goodness John Resig on the jQuery/Microsoft announcement This is cool because we're using jQuery just as it is. It's Open Source, and we'll use it and ship it via its MIT license, unchanged. If there's changes we want, we'll submit a patch just like anyone else. JQuery will also have...
|
-
|
In this series of blog entries, I build an entire MVC Forums application from start to finish. In this entry, I create the user interface for the Forums application by taking advantage of ASP.NET AJAX client templates. I build the entire user interface for the Forums application with a single view and perform all updates to the view with Ajax calls. A page request is just an excuse for a bad user experience. We are conditioned to expect our web pages to freeze whenever we interact with a website. For example, each and every time we submit a form, we expect the browser to freeze and the clock to tick until the browser updates the page again. There is no reason to inflict this pain on the users of your web applications. By taking advantage of...
|
-
|
Rob Bagby is in the midst of a blog series on REST in WCF and been building a series of screencasts on the same subject (in conjunction with Ron Jacobs). Since it's such an interesting topic, especially to AJAX developers I thought I'd share them here. Blog Series: REST in WCF - Part I (REST Overview) REST in WCF - Part II (AJAX Friendly Services, Creating The Service) REST in WCF - Part III (AJAX Friendly Services, Consuming The Service) REST in WCF - Part IV (HI-REST - Exposing a service via GET - Configuring the service) REST in WCF - Part V (HI-REST - Exposing a service via GET - The ServiceContract and Implementation) REST in WCF - Part VI (HI-REST - Consuming our GET service via AJAX) REST in WCF - Part VII (HI-REST - Implementing...
|
-
|
Here is an interesting problem we ran into recently. The customer had a large GridView that was being updated by AJAX inside on UpdatePanel and seeing bad performance. The reason is that the Client-Side Javascript has to walk the entire DOM of the Content of the UpdatePanel to tear down the HTML DOM as the Page goes through an Asynchronous update. First Solution To alleviate the Expensive Stack Walks to destroy DOM Elements and its related Time Delay, the developers suggested that we remove the Unnecessary payload from the DOM of the UpdatePanel during an Asynch Postback. The Way you would implement this is to: 1. Hook up an Event handler to the beginRequest Event . EX: <script language ="javascript" type ="text/javascript">...
|
-
|
In this tip, Stephen Walther demonstrates how you can create an auto-complete text field in an MVC view by taking advantage of the Ajax Control Toolkit. He explains how you can create a custom Ajax Helper that renders the necessary JavaScript. In the previous tip, I demonstrated how you can take advantage of the client file only version of the Microsoft AJAX Control Toolkit to create a popup calendar that you can use as a date picker. See: http://weblogs.asp.net/stephenwalther/archive/2008/08/22/asp-net-mvc-tip-36-create-a-popup-calendar-helper.aspx In this tip, I tackle another one of the behaviors in the toolkit. In this tip, I demonstrate how you can use the AutoComplete behavior to add auto-complete functionality to a text field (see Figure...
|
-
|
I recently got a copy of Advanced ASP.NET AJAX Server Controls For .NET Framework 3.5 . This promises to be a great book. With .NET Framework 3.5, Ajax is really interesting the mainstream and the Ajax Server Controls make it very easy for the millions of ASP.NET developers to easily take advantage of the power Ajax offers. Enjoy it! This is the first book in the .NET Development Series to come out since I was asked to be on the editorial board for the series. It is great to get a chance to work with John Montgomery and Don Box . While the only pay I get for this gig is free books, I am excited to be able to help connect the industry experts on the most important technologies to the widest possible...
|
-
|
Just wanted to pass along some really interesting labs that I came across the other day. These labs cover the following topics: IE 8 Activities AJAX Developer Tools Standards Support IE 8 WebSlices You can check out all these labs at Internet Explorer...
|
-
|
So there is a very good article that came out in the April 2008 issue of the MSDN Magazine, Scaling Strategies for ASP.NET Applications . The main things in this article are: Scaling ASP.NET Applications and databases Optimizing code Using efficient caching...
|
-
|
During the recent Insiders summit, Wally cornered me into recording a really short video demonstrating a feature of ASP.NET MVC. I decided to sprinkle a little Ajax in my demo by showing how to use jQuery to call an action that returns a JsonResult . Specifically, I show how to update a couple of regions in the page (two dom elements) with data pulled from the server. I then add a little sparkle to the demo by implementing the ubiquitous yellow fade when adding the content to the DOM. As you’re watching it, you’ll notice that I’m making it up on the fly based on another demo I did earlier that day. He’s posted the video here in show #106. That’s heckuva a lot of shows Wally! Technorati Tags: aspnetmvc , ajax , jquery Read More...
|