HtmlAnchor Control
When an HTML anchor tag <a> is given a runat="server" attribute, it becomes
accessible through code as an HtmlAnchor control.
Properties
Attributes
a collection of the elements attribute names and their
values
Disabled
if set to True, the control will be disabled
Href
contains the controls link URL
ID
contains the controls ID
InnerHtml
contains the content between the elements opening
and closing tags
InnerText
contains the text between the elements opening and
closing tags
Name
the name of the anchor
Style
contains the controls CSS properties
TagName
returns the elements tag name
Target
contains the target window or frame to be opened
Title
contains the links title
Visible
if set to False, the control wont be visible
Events
ServerClick
raised when the user clicks the link
HtmlButton Control
The HtmlButton control corresponds to the <button runat="server"> HTML
tag.
644
Appendix A: Web Control Reference

Get Build Your Own ASP.NET 2.0 Web Site Using C# & VB, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.