0
UWP 응용 프로그램에서 C# 코드로 웹보기를 만들고 있습니다. LoadCompleted 이벤트를 첨부했습니다. 이 이벤트가 ActaulHeight 및 ActualWidth 트리거를 가져올 때 0입니다. MinWidth 및 MinHeight를 500으로 설정하려고 시도했지만 작동하지 않습니다. ActualHeight 및 ActualWidth in Webview
나는 XAML에서 웹보기 컨트롤을 만들어하지만 경우의 ActualHeight에 같은 일을했고, ActualWidth 여기500 코드입니다 :
public WebView _webView { get; set; }
public ViewPage()
{
this.InitializeComponent();
_webView = new WebView
{
HorizontalAlignment = HorizontalAlignment.Stretch,
VerticalAlignment = VerticalAlignment.Top,
Source = new Uri(@"https://www.google.com"),
MinHeight = 500,
MinWidth = 500
};
}
private void _webView_LoadCompleted(object sender, NavigationEventArgs e)
{
// Here, when I debug _webview ActualHeight and ActaulWidth is zero.
}