Live Chat Icon For mobile
Live Chat Icon

What is an Associated ControlID?

Platform: ASP.NET| Category: Custom Controls

This is the property defined for a Label control in 2.0, which provides linking to an interactive control such as textbox,button,listbox and other controls. It defines a hot key which moves the input focus to the control defined in the property.

<asp:Label ID='Label1' runat='server' AssociatedControlID='TextBox1' Text='Enter Ur Details' 
<asp:TextBox ID='TextBox1' runat='server'></asp:TextBox>

In the above code, TextBox1 gets focused on clicking the Label1, sinced its AssociatedControlID is set to TextBox1.

Share with

Related FAQs

Couldn't find the FAQs you're looking for?

Please submit your question and answer.