I have a grid that uses an edit form template. The template includes a dropdown that needs to control the visibility of other controls on the form based on the selection. I intend to do this with a selected index changed event. How do I get a reference to the edit form controls on the page within a SelectedIndexChanged event of a dropdown?
How do I toggle the visibility of the radtextbox (rtbManagingBrokerLastName) in the selected index changed event of the combobox (rcbDocumentType)?
<EditFormSettings EditFormType="Template"> <EditColumn ButtonType="ImageButton" /> <FormTemplate> <table cellpadding="2" cellspacing="1" border="0" style="font-size: small; border-collapse: collapse; background: white;"> <tr valign="top"> <td colspan="2" align="left"> <b>Document Details</b> </td> </tr> <tr valign="top"> <td class="ContentWhite"> <span class="Error">*</span>Document Type: </td> <td class="ContentWhite" align="left"> <telerik:RadComboBox ID="rcbDocumentType" runat="server" EnableItemCaching="true" MaxHeight="300px" OnSelectedIndexChanged="rcbDocumentType_SelectedIndexChanged"> <Items> <telerik:RadComboBoxItem Value="-Select-" Text="-Select-" /> <telerik:RadComboBoxItem Value="1" Text="W9" /> <telerik:RadComboBoxItem Value="2" Text="E&O" /> <telerik:RadComboBoxItem Value="3" Text="License" /> <telerik:RadComboBoxItem Value="4" Text="Vendor Acknowledgement" /> <telerik:RadComboBoxItem Value="5" Text="Master Listing Agreement" /> <telerik:RadComboBoxItem Value="6" Text="State Registration" /> </Items> </telerik:RadComboBox> <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" Display="None" ValidationGroup="vgDocument" ControlToValidate="rcbDocumentType" InitialValue="-Select-" ErrorMessage=" Document Type is required " /> </td> </tr> <tr valign="top"> <td class="ContentWhite"> <asp:Label ID="lblManagingBrokerFirstName" runat="server" Text="First Name:" Visible="false" /> </td> <td class="ContentWhite" align="left"> <telerik:RadTextBox ID="rtbManagingBrokerFirstName" runat="server" MaxLength="128" /> </td> </tr> <tr valign="top"> <td class="ContentWhite"> <asp:Label ID="lblManagingBrokerLastName" runat="server" Text="Last Name:" /> </td> <td class="ContentWhite" align="left"> <telerik:RadTextBox ID="rtbManagingBrokerLastName" runat="server" MaxLength="128" /> </td> </tr>How do I toggle the visibility of the radtextbox (rtbManagingBrokerLastName) in the selected index changed event of the combobox (rcbDocumentType)?