HTML Server Controls!

A

Adam Knight

Hi All,

I am finding in VS that i can't access properties of HTML Server Controls
from within my code behind file.

Can anyone tell me is this normal?
How do i reference HTML Server Controls from within my code behind file?

Cheers,
Adam
 
A

Adam Knight

To Clarify,

<table ID="UpdteForm" Runat="server" border="0" width="350">
<tr runat="server">
<td runat="server" align="right"><asp:TextBox ID="txtName" Width="200"
Runat="server"></asp:TextBox></td>
<td runat="server" align="right" width="120">
<asp:Button ID="btnUpdate" Runat="server" Text="update"/>
<asp:Button ID="btnCancel" Runat="server" Text="cancel"/>
</td>
<td runat="server" align="right" width="30">
<asp:Button ID="btnSave" Runat="server" Text="save"/>
</td>
</tr>
</table>

In Page_Load Method in my code behind:

When i try to refer to 'UpdteForm.?.?' a message is issued saying
'UpdteForm' hasn't been declared.

Cheers,
AK
 
G

Guest

You have to add a declaration for the HTML table in the code behind file:

Protected UpdteForm as System.Web.UI.HtmlControls.HtmlTable
 

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

Members online

Forum statistics

Threads
473,770
Messages
2,569,585
Members
45,080
Latest member
mikkipirss

Latest Threads

Top