asp.net - How to use external link (url) in a HyperLink

How to use external link (url) in HyperLink control
HyperLinkExternalLink.aspx

<%@ Page Language="C#" %>

<!DOCTYPE html>

<script runat="server">
    protected void Page_Load(object sender, System.EventArgs e)
    {
        HyperLink1.NavigateUrl = "/";
    }
</script>

<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title>How to use external link (url) in HyperLink control</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <h2 style="color:Green">HyperLink Example: External Link</h2>
        <asp:HyperLink 
             ID="HyperLink1"
             runat="server"
             Text="asp.net example blog"
             Font-Size="Large"
             BackColor="MistyRose"
             Font-Italic="true"
             Font-Bold="true"
             >
        </asp:HyperLink>
    </div>
    </form>
</body>
</html>






More asp.net examples