How to re register dynamic scripts registered with ClientScriptManager in asp dot net using session was bad idea
Would it not be better to build a generic script to handle all row scripting requirements, and include once per page? You'll end up with a cleaner end script, and your page footprint will be a lot smaller. You'll also benefit from the browser's resource caching.

Using jQuery, you could achieve something like:

$(function() {
    $("tr.needEvent td").live(function() {
        // Event handler code goes here.
    });
});


where tr.needEvent is a class appended to the &lt;tr&gt; used to wrap a row. If you aren't using tables, this could be used the same way with &lt;div&gt; or any other container element. The important thing is, using .live() we can run the code once, and any other elemnets added to the page that match that selector, will be bound to the event handler automatically.

The use of $(function() { is the jQuery equivalent of Sys.Application.add_load(function() {