Search This Blog

Wednesday, August 24, 2011

Passing a control.ClientID to a javascript function in asp.net


Use below code to pass control client id to javascript function:

<asp:TextBox ID="demo1" runat="server"></asp:TextBox>
<img src="images/cal.gif" onclick="javascript:NewCssCal('<%= demo1.ClientID %>')"
   style="cursor: pointer" alt="sdf" />

Post a Comment

Popular Posts