C#/Xamarin Maui
[Xamarin.Android] WebView 에 html 코드 넣기
kjun.kr
2018. 4. 15. 08:39
728x90
WebView localWebView = FindViewById<WebView>(Resource.Id.LocalWebView);
localWebView.SetWebViewClient(new WebViewClient());
string html = $@"
<html>
<body bgcolor='black'>
<a href ='{urlString}' target='_blank'>
<div style='width: 280px; height: 230px; overflow: hidden; position: relative;'>
<img src='{urlString}' style='position: absolute; top:-15px; left:-95px; width:430px; height: 240px;'/>
</div>
</a>
</body>
</html>
";
localWebView.LoadData(html, "text/html", null);
728x90