O'Reilly logo

C# Primer: A Practical Approach by Stanley B. Lippman

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

7.4. The HyperLink Control: Linking to Other Pages

One common task we need to provide for is that of navigating links to other pages, both third-party Web links, such as http://www.amazon.com, and other ASP.NET pages in our project. We do this with the HyperLink control, setting its NavigateUrl property to either a URL or another page. The Text property displays the description of the link—for example, See Margaret & Nancy at Recital! is the text of a HyperLink control in Figure 7.1.

The NavigateUrl string can be any valid Web location. For example, the NorthWind link displays a Renoir painting of a piano recital currently available at

http://www.ibiblio.org/wm/paint/auth/renoir/renoir.filles-piano.jpg

Alternatively, if we click to the right ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required