S susu Well-Known Member Licensed User Longtime User Dec 15, 2014 #1 In B4A, I can use WebViewXtender to disable the scroll bar. How can I do this in B4i?
Erel B4X founder Staff member Licensed User Longtime User Dec 15, 2014 #2 Try this: Code: Copy Dim no As NativeObject = WebView1 no.GetField("scrollView").SetField("scrollEnabled", False) Upvote 0
Try this: Code: Copy Dim no As NativeObject = WebView1 no.GetField("scrollView").SetField("scrollEnabled", False)
S susu Well-Known Member Licensed User Longtime User Dec 15, 2014 #3 Thanks! I set the background to transparent but why it still White? Upvote 0
S susu Well-Known Member Licensed User Longtime User Dec 15, 2014 #4 Erel said: Try this: Code: Copy Dim no As NativeObject = WebView1 no.GetField("scrollView").SetField("scrollEnabled", False) Click to expand... I was wrong. I want to hide scroll bar of webview not disable scroll. Something like this: webView.scrollView.showsHorizontalScrollIndicator = NO; webView.scrollView.showsVerticalScrollIndicator = NO; I tried: no.GetField("scrollView").SetField("showsHorizontalScrollIndicator", "NO") but it doesn't work. Upvote 0
Erel said: Try this: Code: Copy Dim no As NativeObject = WebView1 no.GetField("scrollView").SetField("scrollEnabled", False) Click to expand... I was wrong. I want to hide scroll bar of webview not disable scroll. Something like this: webView.scrollView.showsHorizontalScrollIndicator = NO; webView.scrollView.showsVerticalScrollIndicator = NO; I tried: no.GetField("scrollView").SetField("showsHorizontalScrollIndicator", "NO") but it doesn't work.
Erel B4X founder Staff member Licensed User Longtime User Dec 15, 2014 #5 It should be False instead of "NO". Upvote 0
S susu Well-Known Member Licensed User Longtime User Dec 15, 2014 #6 It still doesn't work: [<_UIWebViewScrollView 0x16eb7190> setValue:forUndefinedKey:]: this class is not key value coding-compliant for the key showsVerticalScrollIndicator . EDIT: It worked! I typed a wrong space! Upvote 0
It still doesn't work: [<_UIWebViewScrollView 0x16eb7190> setValue:forUndefinedKey:]: this class is not key value coding-compliant for the key showsVerticalScrollIndicator . EDIT: It worked! I typed a wrong space!
Erel B4X founder Staff member Licensed User Longtime User Dec 15, 2014 #7 I tried it with this code and it worked: Code: Copy Dim wv As WebView wv.Initialize("wv") Dim no As NativeObject = wv no.GetField("scrollView").SetField("showsHorizontalScrollIndicator", False) no.GetField("scrollView").SetField("showsVerticalScrollIndicator", False) Upvote 0
I tried it with this code and it worked: Code: Copy Dim wv As WebView wv.Initialize("wv") Dim no As NativeObject = wv no.GetField("scrollView").SetField("showsHorizontalScrollIndicator", False) no.GetField("scrollView").SetField("showsVerticalScrollIndicator", False)