hi Mark

  Thank you for your help. I've got it.

  This is my code to load js file dynamic after load Web page. I hope
it will help other friends who troubled by same question.

  ====android code begin====
  final class MyWebViewClient extends WebViewClient {
    @Override
    public void onPageFinished(WebView view, String url) {
      String loadJsFile = "javascript:"
                        + "void("
                        + "(function(){"
                        + "var e=document.createElement('script');"
                        + "e.setAttribute('src','wasuTVDemo.js');"
                        + "document.body.appendChild(e);}"
                        + ")()"
                        + ")";
      mWebView.loadUrl(loadJsFile);
    }
  }
  ====android code end====

On 6月30日, 下午7时14分, Mark Murphy <mmur...@commonsware.com> wrote:
> Use loadUrl("javascript:..."), as with a bookmarklet.
>

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to