protected void GridView1_RowDataBound(object sender, GridViewRowEventArgs e)
{
if (e.Row.RowType == DataControlRowType.DataRow)
{
Button TB = (Button)e.Row.FindControl("btnpickdate");
TextBox tb = (TextBox)e.Row.FindControl("TxtDate");
TB.Attributes.Add("onclick", "javascript:showCalendarControl(document.getElementById('" + tb.ClientID + "'))");
}
}
Supa Sethasiripong [MSFT]
MSDN Community Support |
Feedback to us
Get or Request Code Sample from Microsoft
Please remember to mark the replies as answers if they help and unmark them if they provide no help.