Using Hyperlink in WPF application

To user hyperlink in WPF application we could do something like this



<Hyperlink NavigateUri=””&gt;

            Click here




However the NavigateUri works only if we are placing the hyperlink within a page. To use it within a windows-based application we need to hanlde the RequestNavigate event and write the code ourselves.


Something like this



<Hyperlink NavigateUri=”; RequestNavigate=”Hyperlink_RequestNavigate”>

 Click here




private void Hyperlink_RequestNavigate(object sender, RequestNavigateEventArgs e)


            Process.Start(new ProcessStartInfo(e.Uri.AbsoluteUri));

            e.Handled = true;



While using hyperlink we could also provide handler for Application.NavigationFailed event in case if navigation fails.


That’s it ….


Author: Nishant Rana

I love working in and sharing everything about Microsoft.NET technology !

13 thoughts on “Using Hyperlink in WPF application”

  1. Very helpful. Just want to add that

    Application.NavigationFailed EventHandler goes into the App.Xaml class and might look like this:

    private void App_NavigationFailed (object sender, NavigationFailedEventArgs e)
    if (e.Exception is System.Net.WebException)
    //code to handle error here, such as a messagebox to the user

    e.Handled = true;


  2. Hi,
    I am Naga Harish from chennai. I need one help from you. I want write Microsoft certification in ASP.Net. I need your guide lines. You can my gmail ID to send reply ( . I have some Q? too. Please help me!


  3. This doesnt seem to work unless i add a this.DataContext = “something” into my main window class. this is causing issues for me as i have a relativesource binding set to my datacontext in the xaml. how can i get around this? thanks! great article btw


  4. Hi,

    Just one question, please….

    In the code line “Process.Start(new ProcessStartInfo(e.Uri.AbsoluteUri));”… what stands for Process?? I´m trying to write your code and I got an error regarding that line…

    Thanks in advance


  5. I’m using the code below. I hope it can help you.

    Click here!

    private void Hyperlink_RequestNavigate(object sender, System.Windows.Navigation.RequestNavigateEventArgs e)
    System.Diagnostics.Process.Start(new System.Diagnostics.ProcessStartInfo(e.Uri.AbsoluteUri));
    e.Handled = true;


  6. Good day! I know this is somewhat off topic but I was wondering if you
    knew where I could locate a captcha plugin for my comment form?
    I’m using the same blog platform as yours and I’m having difficulty finding one?
    Thanks a lot!


Please share your thoughts

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

CRM for You and Me

Customer Relationship Mgt App for the Professional

D CRM Explorer

Learn about Microsoft Dynamics CRM Power Platform customization and implementation and other cool stuffs

Stroke // Jonas Rapp

I know pre-stroke. I will improve who I was.

Power Melange

Power Melange By Shalinee

Clavin's Blog

Power Automate - Power Apps - SharePoint Online - Azure - Nintex - K2 - Artificial Intelligence

Sat Sangha Salon

An Inquiry in Being

The Indoencers

The Influencers & Influences of Indian Music

Monika Halan's blog

Hand's-free money management

D365 Demystified

A closer look at Microsoft Dynamics 365.

Microsoft Mate (msftmate) - Andrew Rogers

Experienced consultant primarily focused on Microsoft Dynamics 365 and the Power Platform


Specific topics by Django Lohn on the whole Microsoft365 Stack

Manmit Rahevar's Blog

One Stop Destination for Microsoft Technology Solutions


Naturally Curious

Brian Illand

Power Platform and Dynamics 365

Steve Mordue MVP

A Microsoft Business Applications MVP

Subwoofer 101

Bass defines your home theater

SQLTwins by Nakul Vachhrajani

SQL Server tips and experiences dedicated to my twin daughters.

Everything D365

Discovering Azure DevOps and D365 Business Applications

Tech Wizard

Lets do IT Spells

Two Bite Tips

Valuable Tips To Grow Your Business

XRM Tricks (Power Platform & Dynamics CRM )

Power Platform & Dynamics CRM


Mail to for queries and suggestions

Giving back to the community what I have learned

xrm CRM Dynamics

Dynamics CRM Technical & Functional Info

Dynamics 365 Blogs - Explained in unique way

Sometimes you need to look at things from different perspective.

CRM Keeper

Dynamics 365 Customer Engagement, CRM, Microsoft CRM, Dynamics CRM


Step into the world of a Dynamics 365 Consultant

Dianamics PCF Lady

Diana & Dynamics 365 & Power Platform

Sara Lagerquist

No Code Customization Concepts


developer, designer, writer, fun loving, patriotic, humble and a sweet person inside out :) love and respect people who have a great sense of humor.

Temmy Wahyu Raharjo

Dreaming to be a clean coder and TDD minded programmer.

Transform 365

We blog about problems we face and code we write to help others

%d bloggers like this: