asp.net.ph

HyperLink.Text Property

System.Web.UI.WebControls Namespace   HyperLink Class


Sets or retrieves the text displayed for a HyperLink control.

Syntax


Inline <asp:hyperlink text = strtext ... >
Script HyperLink.Text [ = strtext ]

Property Value


strtext String that specifies the text caption for the hyperlink.

The property is read/write with no default value.

Remarks

Use the Text property to specify or determine the caption displayed for the HyperLink control.

If an ImageUrl is defined, it will take precedence over this property. This property will then be used as the alternate text for the image.

In certain cases, as when hyperlinks are used within templated controls, the Text property is usually obtained dynamically from a data source.

Example

The following example shows how to declaratively set the Text property of a HyperLink control at design time.

<asp:hyperlink runat = "server" 
   text = "Simply awesome"
   navigateurl = "~/index.aspx" />
See Also

HyperLink Members   ImageUrl   NavigateUrl Skip Navigation Links




Home
Suggested Reading


Previous page Back to top Next page

© 2000-2010 Rey Nuñez All rights reserved.

If you have any question, comment or suggestion
about this site, please send us a note

You can help support asp.net.ph