Thursday, September 30, 2010

[android-developers] WebView - Documentation of JavaScript and Java Interaction

Hello Developers,

I have found that there is a significant lack of documentation of
WebView's ability to communicate with Java via WebView.addJavaScript()
method. First, the debug document
appears to no longer work. Second, what object types should we expect
when going to and from JavaScript. I have done some trial and error
and it appears that complex types can cross the boundary, for example
java.util.Vector. However when a Java method returns a byte array to
JavaScript it has a type of undefined and I have been unable to coerce
it to any other type. Finally, there is great potential with this
interface and with some more attention we could go far.


You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to
To unsubscribe from this group, send email to
For more options, visit this group at

No comments:

Post a Comment