Attention: We are retiring the ASP.NET Community Blogs. Learn more >

Meet your new friend ClientScript in ASP.NET 2.0

In ASP.NET 1.X for rendering client side script to client browser we took help of Page.RegisterClientScriptBlock or Page.RegisterStartupScript methods! But these methods are obsolete in ASP.NET 2.0 (As always Microsoft facilitates backward compatibility in its products, we can still use these, but these are not recommended to use)

 

In 2.0, we can take help of Page.ClientScript to render client side script to client browser.

Page.ClientScript property is wraps an instance of the ClientScriptManager type. This ClientScriptManager helps managing scripts.

 

That’s not it; there is more to know about this guy (ClientScript). Very interesting internals are there behind introducing this new ClientScript feature in ASP.NET 2.0.

 

If you just met ClientScript, start exploring it : )

3 Comments

Comments have been disabled for this content.