Note: Advice in this article will only work for DotNetBrowser 1.
See the corresponding article for DotNetBrowser 2 here.

DotNetBrowser API provides functionality that you can use to handle loading and decide whether specified URL should be loaded in Chromium engine or not. The following sample code demonstrates how to register LoadHandler which will cancel navigation to all URLs that start with 


private class CustomLoadHandler : DefaultLoadHandler
  public override bool OnLoad(LoadParams loadParams)
    return loadParams.Url.StartsWith(@"");

browser.LoadHandler = new CustomLoadHandler();


Private Class CustomLoadHandler
    Inherits DefaultLoadHandler

    Public Overrides Function OnLoad(ByVal loadParams As LoadParams) As Boolean
        Return loadParams.Url.StartsWith("")
    End Function
End Class

browser.LoadHandler = New CustomLoadHandler()