B4i didn't have WebView extra library (yet) so I collect the code from around the forum. Hope it's useful for you.
1. Hide scrollbar of WebView:
2. Set background to transparent:
3. Disable Scroll:
4. Go Back:
5. Clear Cache:
I will update more.
1. Hide scrollbar of WebView:
B4X:
Dim no As NativeObject = WebView1
no.GetField("scrollView").SetField("showsHorizontalScrollIndicator", False)
no.GetField("scrollView").SetField("showsVerticalScrollIndicator", False)
2. Set background to transparent:
B4X:
Dim no As NativeObject = WebView1
no.SetField("opaque", False)
3. Disable Scroll:
B4X:
Dim no As NativeObject = WebView1
no.GetField("scrollView").SetField("scrollEnabled", False)
4. Go Back:
B4X:
Sub GoBack(wv As WebView)
Dim no As NativeObject = wv
If no.RunMethod("canGoBack", Null).AsBoolean = True Then
no.RunMethod("goBack", Null)
End If
End Sub
5. Clear Cache:
B4X:
Dim no As NativeObject
no.Initialize("NSURLCache").RunMethod("sharedURLCache", null).RunMethod("removeAllCachedResponses", null)
I will update more.
Last edited: