Geeks With Blogs

News Photo of Tanzim Saqib Tanzim Saqib is a Senior Developer, who spent half of his life on software and worked for many companies like #1 .NET controls provider Telerik Inc, #1 personalized Web 2.0 start-page like Pageflakes (acquired by LiveUniverse). He developed many projects ranging from banking solutions for Citibank, HSBC, Wamu, Wells Fargo etc. to Paperless Virtual University. He is industry's earliest and leading widget developer and as know as "Widget Master" to his peers.

He is a preacher of Microsoft technologies. While he jams with the latest additions to .NET, in his spare time he blogs at, maintains his personal website, leads .NET Research group. writes articles.

He is an easy going, fun loving, and passionate technology individual who is open to any kind of business opportunity and professional relationship. He currently lives in Bangladesh, but travels anywhere in the world on professional demand.

Email: me at TanzimSaqib dot com
Tanzim Saqib on .NET discovery Innovate. Create. Share. JavaScript
CallQueue: Implementing a Sequential Web Service Call Queue for AJAX application
In AJAX based applications its common that user might end up breaking your AJAX calls by clicking on numerous places in very short interval of time. Let us assume there is a page where there are several of hyperlinks which make WebService calls and do some stuffs on callback. If user clicks on five hyperlinks being impatient or may be just for fun, there will be five different WebService calls made. All of those calls had the same parameters or UI state while they were invoked. But on completion ......

Posted On Wednesday, November 19, 2008 4:11 PM

jQuery intellisense in Visual Studio
Those who are excited like me about the news of jQuery integration into Visual Studio, started adopting jQuery replacing ASP.NET AJAX Client side API. Microsoft also declared there will be a patch for Visual Studio which will support jQuery as well as intellisene for that. For the enthusiasts who just can't for it, here is the way how we can start developing using jQuery with full intellisense support inside Visual Studio 2008: 1. Download jquery-1.2.6-vsdoc.js 2. Inside your JavaScript files, add ......

Posted On Tuesday, October 28, 2008 9:21 AM

ASP.NET AJAX Best Practices: Careful with DOM element concatenation
It's a very common bad practice. We often iterate through array, build HTML contents and keep on concatenating into certain DOM element. Every time you execute the block of code under the loop, you create the HTML markups, discover a div, access the innerHTML of a div, and for += operator you again discover the same div, access its innerHTML and concatenate it before assigning. function pageLoad() { var links = ["", "", ""]; $get('divContent').innerHTML = 'The following ......

Posted On Tuesday, February 5, 2008 6:51 AM

[New Article] ASP.NET AJAX Best Practices
While we develop AJAX applications, we often carelessly ignore giving up bad practices, which cause effects which are not so significantly visible when the site is not so large in volume. But, it’s often severe performance issue when it is the case for sites that make heavy use of AJAX technologies such as Pageflakes, NetVibes etc. There are so many AJAX widgets in one page that little memory leak issues combined may even result the site crash into very nasty “Operation aborted”. There are a lot ......

Posted On Sunday, January 27, 2008 1:21 AM

ASP.NET AJAX Best Practices: Reduce scopes
It's not pretty common. But, if you ever encounter such code, be sure it's a very bad practice. Introducing more scopes is a performance issue for JavaScript interpreter. It adds a new scope in the ladder. See the following sample scope:function pageLoad() { scope1(); function scope1() { alert('scope1'); scope2(); function scope2() { alert('scope2'); } } } Introducing more scopes enforces the interpreter to go through new more sections in the scope chain that it maintains for code execution. So, ......

Posted On Sunday, January 6, 2008 7:44 PM

ASP.NET AJAX Best Practices: Avoid using your own method while there is one

Avoid implementing your own getElementById method that will cause script to DOM marshalling overhead. Each time you traverse the DOM and look for certain HTML element requires the JavaScript interpreter to marshalling script to DOM. It's always better to use getElementById of document object. So, before you write a function, make sure similar functionality can be achieved from some other built-in functions.

Posted On Sunday, January 6, 2008 8:11 AM

ASP.NET AJAX Best Practices: Avoid String concatenation, use Array instead
Don't you think the following block of code has written keeping every possible good practice in mind? Any option for performance improvement?function pageLoad() { var stringArray = new Array(); // Suppose there're a lot of strings in the array like: stringArray.push('<div&g... stringArray.push('some content'); stringArray.push('</div&... // ... code edited to save space var veryLongHtml = $get('divContent').innerHTML; var count = stringArray.length; for(var i=0; i<count; ++i) veryLongHtml ......

Posted On Tuesday, January 15, 2008 6:44 AM

ASP.NET AJAX Best Practices: Introduce function delegates
Take a look at the following loop. This loop calls a function in each iteration and the function does some stuffs. Can you think of any performance improvement idea?for(var i=0; i<count; ++i) processElement(elements[i]); Well, for sufficiently large array, function delegates may result in significant performance improvement to the loop.var delegate = processElement; for(var i=0; i<count; ++i) delegate(elements[i]); The reason behind performance improvement is, JavaScript interpreter will use ......

Posted On Saturday, January 12, 2008 6:46 AM

ASP.NET AJAX Best Practices: Introduce DOM elements and function caching
We have seen DOM caching before and function delegation is also a kind of function caching. Take a look at the following snippet: for(var i=0; i<count; ++i) $get('divContent').appendCh... As you can figure out the code is going to be something like: var divContent = $get('divContent'); for(var i=0; i<count; ++i) divContent.appendChild(elem... That is fine, but you can also cache browser function like appendChild. So, the ultimate optimization will be like the following: ......

Posted On Friday, January 11, 2008 6:48 AM

ASP.NET AJAX Best Practices: Problem with switch

Unlike .NET languages or any other compiler languages, JavaScript interpreter can not optimize switch block. Especially when switch statement is used with different types of data, it's a heavy operation for the browser due to conversion operations occur in consequences, it's an elegant way of decision branching though.

Posted On Thursday, January 10, 2008 7:26 PM

Copyright © Tanzim Saqib | Powered by: