Hai,
r u trying to add a textbox control in codebehind then in the page after the button place a panel or placeholder.And in the codebehind add the textbox to the panel as follows
in Code behind
TextBox TxtBox = new TextBox();
TxtBox.ID = "TxtRName";
TxtBox.Text = "Test";
TxtBox.Width=100;
PnlName.Controls.Add(TxtBox);
after button,
<asp:button >
csharp_r <[EMAIL PROTECTED]> wrote:
Yahoo! India Matrimony: Find your partner now.
YAHOO! GROUPS LINKS
<asp:PlaceHolder id="PnlName" runat="server"></asp:PlaceHolder >
try this.
Rajesh.S
csharp_r <[EMAIL PROTECTED]> wrote:
Hi, when i want to add a control (for example TextBox) in a webform in
click event of a Button, it has an error like this:
"Control '_ctl0' of type 'TextBox' must be placed inside a form tag
with runat=server"
what's this and how i can solve this problem ?
Yahoo! India Matrimony: Find your partner now.
YAHOO! GROUPS LINKS
- Visit your group "Microsofts_C_Sharp" on the web.
- To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
- Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
- [Microsofts_C_Sharp] a problem to add a control in a webform csharp_r
- RE: [Microsofts_C_Sharp] a problem to add a control in a web... Rob
- Re: [Microsofts_C_Sharp] a problem to add a control in a web... Rajesh S
