server control on masterpage


C

CreativeMind

hi, a simple problem is there.
i m facing problem
"Control '_ctl0_txtUserName' of type 'TextBox' must be placed inside a
form tag with runat=server."

actually i have a master page which has a textbox. In the master page
(.master) file,
i m using a condition
-----------
<% if(istrue)%>
<tr><td><asp:textbox id="t" runat="server" ></textbox></td>
</tr>
<%}%>
-----------

when i send request to some content page, i face problem on master
page describing

"Control '_ctl0_txtUserName' of type 'TextBox' must be placed inside a
form tag with runat=server."
<% } %>


how can i resolve that..
thanx
 
Ad

Advertisements

C

CreativeMind

I got it..simple <form> tag is not enough.. <form runat="server"> is
must thing..
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top