Answer the question
In order to leave comments, you need to log in
How to place an object of the WebBrowser class on a WPF window?
There is a WPF window, through the constructor to which an object of the WebBrowser class was passed. How to place this object on a WPF window?
Answer the question
In order to leave comments, you need to log in
I found an error. The matter is that there is System.Windows.Forms.WebBrowser, and there is System.Windows.Controls.WebBrowser and they cannot replace each other. That's why I couldn't add a browser via myGrid.Children.Add. thanks for answers
Mb in the xaml'a graphical editor to drag the WebBrowser object from the toolbox to the window layout?
In this case, a new control is created, not from an object. I need a second case
The window has a Content property that contains the root layout, which can be, for example, Grid. You can add a WebBrowser to this layout:
myGrid.Children.Add(myWebBrowser);
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question