B4J Question webview showing blank page

le_toubib

Active Member
Licensed User
Longtime User
hello there
i 'm using this code to load html from a file into a webview
however there result is a blank page
what am i doing wrong :
B4X:
Sub showpreview

    Dim tr As TextReader
    Dim fn As String
    fn =  dirname & "w_" & acet1.Text.Replace(" ","_") & DateTime.Date(DateTime.Now) & "/" &  "report_for_browser.html"
    tr.Initialize(File.OpenInput(File.Dirapp, fn))
    Webview1.LoadHtml(tr.ReadAll)
    Webview1.Visible=True


End Sub
indeed the sub is accessible when called, and file can be opened in any browser, i tried .loadhtml method to load the text directly from a string , but same results
thanks
 
Top