See Also: HyperLink Members
System.Object
System.Web.UI.Control
System.Web.UI.WebControls.WebControl
System.Web.UI.WebControls.HyperLink
System.Web.UI.WebControls.HyperLink shows a link (yes, those that you know widely from the web). It resolves the relative path names and translate it to a relative path in terms of the root of the website.
Use it widely instead of plain html tags. One benefit is that you'll be able of managing the link programatically, and will be able to detect broken links. Of course, you'll have to program DetectBrokenLinks() first :-)
There could be some thoughts such as "why should I use it, since I could use a flat html?". Well, System.Web.UI.Controls.HyperLink provides some nice features, and especially one that many web developers were missing: The handling of relative and/or absolute path names. When I develop a website in my machine, I never use the root of the webserver, because it would left unusable for other projects. Rather, I use a subdirectory or a user path; thus, locally my website is something like http://localhost/mywebsite/ or http://localhost/~me/mywebsite/. Later I deploy it to the root of http://www.mywebsite.com, and here I have the problem: The path to aage in my machine is /mywebsite/images/goofy.jpg, but in the website, it becomes /images/goofy.jpg. Well, using an System.Web.UI.WebControls.HyperLink object I don't have to worry about it any more: I just set the hyper-reference to relative paths (images/goofy.jpg, goofy.jpg, ./images/goofy.jpg or ../../../images/goofy.jpg) and the ASP.NET engine will translate it to the correct representation.
Namespace: System.Web.UI.WebControls
Assembly: System.Web (in System.Web.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0