Private Sub loadFileToWebView(WV As WKWebView, Dir As String, FileName As String, isImage As Boolean) 'ignore
If isImage Then
' WV.LoadUrl(xui.FileUri(Dir, FileName))
WV.LoadHtml("<html><head></head><body><div class=" & """" & "container" & """" & "> <img src= """ & "file://" & xui.FileUri(Dir, FileName) & """/><style>.container {width: 100%;height: 100%;position: absolute;margin:auto;top:0;bottom:0;left:0;right:0;background-color: #fff;}img {max-width: 100%;max-height: 100%; position: absolute;margin:auto;top:0;bottom:0;left:0;right:0;}<style></body></html>")
Else
WV.LoadUrl(xui.FileUri(Dir, FileName))
End If
End Sub