I have dropdownlist and I have added javascript to show the contents(e.g. person 1, person 2 etc).
I used below the code but textbox wasn’t displayed.
innerHtml = innerHtml + <asp:TextBox runat=server ID=txtName3 MaxLength=100 Text=''></asp:TextBox>
No, you cannot, as ASP.NET controls are executed on the server, not on the client.
You can add HTML
inputtag instead.What you probably want to do is to use
UpdatePanelto refresh part of your page after changing selection in dropdown.