Is there a way to programmatically select all WebView content?
I know how to put the WebView into "text selection mode". But that relies on the user to do the selection, manually.
If there is a way to programmatically select all WebView content, how do I do that?
There is no way to select something in WebView programmatically.
try mWebview.evaluateJavascript("document.execCommand('selectAll');",null);
In Javascript you can iterate across all the "elements" and call .select()
on each one of them. Nothing specific to Android though.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With