B4J Question ShowExternalDocument only works in Debug

Roger Daley

Well-Known Member
Licensed User
Longtime User
Hi All,

I am using "ShowExternalDocument" to display a HTM file. It works when I compile in Debug mode but when I compile in Release mode I get a pop up that tells me I need an App.

B4X:
Sub Help_action
    fx.ShowExternalDocument(File.GetUri(File.DirAssets, "helpfile.htm"))
End Sub

Any Ideas?


Regards Roger

B4J.jpg
 

eurojam

Well-Known Member
Licensed User
Longtime User
Hi Roger,
that is because the Assetfolder will not be accessible to other programs in the release state of your programm, the files are packaged inside the Jar files. Put the help file into the File.DirApp folder and it will work in release mode...

best stefan
 
Upvote 0

eurojam

Well-Known Member
Licensed User
Longtime User
But why don't you use a webview in your b4j app. It is also available in b4j, then you can leave your html file in the asset folder...:)
 
Upvote 0
Top