[SOLVED] Load local HTML file into jWebView
lazarus / 43-Android
----------------------------------------------------------------------
maurobio · 2023-05-26 12:30
Dear ALL,
Is there any way of loading and displaying a local HTML file using a
jWebView component?
Presuming this is possible, where should the HTML go? Should it be
placed in the app 'assets' folder?
A simple code (even one-line) example of using jWebView for this
purpose will be much helpful!
Thanks in advance!
With warmest regards,
----------------------------------------------------------------------
jmpessoa · 2023-05-26 22:52
jWebView methods:
Code: Pascal [Select][+][-]window.onload = function(){var x1 =
document.getElementById("main_content_section"); if (x1) { var x =
document.getElementsByClassName("geshi");for (var i = 0; i
Procedure LoadFromHtmlFile(environmentDirectoryPath: string;
htmlFileName: string); procedure LoadFromHtmlString(_htmlString:
string);
----------------------------------------------------------------------
maurobio · 2023-05-27 12:56
Hi, @jmpessoa!
This is what I needed!
BTW, where can I find the class definition for the jWebView component?
Thanks a lot!
Best regards,
----------------------------------------------------------------------
jmpessoa · 2023-05-27 17:22
Quotewhere can I find the class definition for the jWebView component?
put the cursor above some code ( jWebView ?) then do: "ctl + mouse
click"
----------------------------------------------------------------------
c4p · 2023-05-28 08:27
I did not know this, this is super useful, thank you!
Quote from: jmpessoa on May 27, 2023, 07:22:52 pmQuotewhere can I find
the class definition for the jWebView component?
put the cursor above some code ( jWebView ?) then do: "ctl + mouse
click"