JQuery Row Selection & Changing Styles

JQuery can be extremely FAST as compared to normal Javascript routines. Like in case we want to select a row in html table, and want to change the style of that row, and also remove selected style from other rows of the same table. (Options are limitless)

function SelectRow(rowObject)


    $(“#tableId TR “) .removeClass(“SelectedRowStyle”).addClass(“OriginalRowStyle”);//removes SelectedRowStyle and add Original

  //Option – more faster can be $(“#tableId TR .SelectedRowStyle”) .removeClass(“SelectedRowStyle”).addClass(“OriginalRowStyle”);

   $(this).removeClass(“OriginalRowStyle”).addClass(“SelectedRowStyle”); //removes the Original Style and add Selected class


Now, if wanted to the same in Javascript we would need to loop through all rows and then search for selected row and do all other stuff we need to for javascript. This is simple in its own way…



Asp.net Caching & Scalibility

Today, we ran across the requirement of using Cache in our web garden/ farm enabled product called LoanVantage. Though we already knew that it would not work under current default implementation of caching in asp.net, but it seemed we had little choice of what to use or not. 

So, suddenly GOOGLING suggested us to a name “Velocity” for caching… and it was none other than Microsoft’s Solution, though in CTP but it was something to look on. So digging in more deeply downloaded this from http://www.microsoft.com/downloads/details.aspx?FamilyId=B24C3708-EEFF-4055-A867-19B5851E7CD2&displaylang=en 

With help of little code in samples – we were rocking in one hour and were ready to test our application with all this stuff. Though its in CTP, but quite useful – some enhancements would be needed to make it work beautifully.

 You can find more details on http://msdn.microsoft.com/en-us/windowsserver/ee695849.aspx