Hi. I'm usually a new member here. I know there is a way to get if Firefox is your default browser or other browsers..

Its not http for getting the default browser. but it's the ".htm" extension you should check.

How did I find out?
I've tested changing "FirefoxHTML" into another string that is not for firefox then I started running firefox.
When it opens, it says that firefox is not your default browser.


So here is the code that I wrote:
Code:
    Public Function GetDefaultBrowser() As String
        Dim GetLink As String = My.Computer.Registry.GetValue("HKEY_CLASSES_ROOT\.htm", "", "")
        'Gets the default value of the .htm extension for locating the default browser's parameter

        Dim Result As String = My.Computer.Registry.GetValue("HKEY_CLASSES_ROOT\" + GetLink + "\shell\open\command", "", "")
        'Gets the shell command of the default browser to be returned.
        Return Result.ToString
    End Function
So if your default browser is firefox, then it will appear the code below
Code:
"C:\Program Files (x86)\Mozilla Firefox\firefox.exe" -requestPending -osint -url "%1"
If you want to browse something, then just replace "%1" to the web you like.

Example:
Code:
        Dim WebLocation As String = GetDefaultBrowser.Replace("%1", "vbforums.com")
        Shell(WebLocation)
        'Replace vbforums.com to any location in the web to be launched by the default browser.
I hope this helped you [gja].