Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8339997
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T05:02:46+00:00 2026-06-09T05:02:46+00:00

I have a WPF navigator control where I’m trying to do something to the

  • 0

I have a WPF navigator control where I’m trying to do something to the effect of the following so I can clean a URL up before going to the clipboard:

if (webBrowserWorkflows.Source = "http://testinglink.com")
{
     // do stuff
}

Unfortunately when I try to do this Visual Studio tells me: “Cannot convert source type string to System.URI”.

With this in mind I’ve tried:

if (webBrowserWorkflows.Source.ToString = "http://testinglink.com")
{
     // do stuff
}

However I’ve had no success. As I’m sure you can tell I’m quite new to C# – this is a bit of a testing ground for me so any documention you can provide with an answer to help me to understand that answer would be very much appreciated!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T05:02:48+00:00Added an answer on June 9, 2026 at 5:02 am

    You need to create a new URI object, you can pass your URL into the constructor, this should work:

    using System;
    
    ...
    
    URI myUri = new URI("http://testinglink.com"); 
    
    webBrowserWorkFlows.Source = myUri;
    //OR    
    webBrowserWorkFlows.Navigate(myUri);
    ...
    
    if (webBrowserWorkflows.Source == myUri)
    {
        // do stuff
    }
    

    http://msdn.microsoft.com/en-us/library/system.uri.aspx

    http://msdn.microsoft.com/en-us/library/system.windows.controls.webbrowser.aspx

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a WPF System.Windows.Controls.WebBrowser control in a Window. A user can enter information
I seem to be going round in circles. I have a WPF application that
I have a C# WPF application with a web browser control (System.Windows.Controls.WebBrowser) called wB.
I have a WPF WebBrowser object in my application in which I am trying
I have a problem trying to develop a WPF page. I have a window
I have a simple WPF webBrowser control that I am using to automate a
I'm developing a WPF application using MVVM. Inside a Window, I have a control
I have a WPF where I am implementing a WebBrowser control and I have
How can use the WebBrowser control in WPF to navigate using Search engine uri
Using WPF, I have a ListBox control with a DataTemplate inside it. The relevant

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.