wv.LoadHtml("<html><body> <img src=" & QUOTE & "file://" & Notes & QUOTE & " id='img1' ></body></html>")
....
Sub wv_PageFinished (Url As String)
If Flag = 0 Then
Flag = 1
Do_JS("document.getElementById(" & QUOTE & "img1" & QUOTE & ").naturalHeight")
wait for Show_result(res As String)
ImgHeight = res
Rate = hsv.Height/ImgHeight
Do_JS("document.getElementById(" & QUOTE & "img1" & QUOTE & ").naturalWidth")
wait for Show_result(res As String)
ImgWidth = res
hsv.Panel.Width = ImgWidth * Rate
wv.Width = ImgWidth * Rate
pnl.Width = ImgWidth * Rate
wv.LoadHtml("<html><body> <img src=" & QUOTE & "file://" & Notes & QUOTE & " id='img1' ></body></html>")
Else
ProgressDialogHide
Log("stop")
End If
End Sub
Sub Do_JS (JS As String)
Dim Javascript As String
Javascript="B4A.CallSub('Process_HTML', true, " & JS & ")"
WebViewExtras1.executeJavascript(Javascript)
End Sub
Sub Process_HTML(Html As String)
CallSubDelayed2(Me, "Show_result", Html)
End Sub
Sub lblAction_Click
WebViewExtras1.SetInitialScale(100 * Rate)
hsv.Visible = True
End Sub