New to Telerik UI for WPF? Download free 30-day trial

Host WebBrowser in RadWindow

A common scenario that you might want to achieve is hosting a WebBrowser control in a RadWindow. However, by default the RadWindow does not support this, because it is displayed into a transparent WPF Window and the WPF Window doesn't support hosting a WebBrowser control when it is in transparent mode.

Setting the Transparancy of the RadWindow

In order to achieve the requirement described above, you can utilize the RadWindowInteropHelper class in order to set the AllowTransparency attached property on the RadWindow. Example 1 demonstrates this approach.

Example 1: Hosting a WebBrowser in RadWindow

var window = new RadWindow 
    Content = new WebBrowser { Source = new Uri("") }, 
    Width = 700, 
    Height = 500 
RadWindowInteropHelper.SetAllowTransparency(window, false); 
Dim window = New RadWindow With { 
    .Content = New WebBrowser With {.Source = New Uri("")}, 
    .Width = 700, 
    .Height = 500 
RadWindowInteropHelper.SetAllowTransparency(window, False) 

Figure 1: Result from Example 1 in the Office2016 theme

WebBrowser in RadWindow

See Also

In this article