Oops.  :)

I did not look at your lesson.  I did however use webview for one of my
first activities I built in Android after sucessfully completing the
helloandroid lesson, and it worked a charm for me.  Here is the code which
works fine for me.  HTH, Happy coding.

Public class webtest extends Activity (
        WebView webview; //declare webview variable
        @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
          webview = (WebView) findViewById(R.id.webview); //link java code
to xml gui
        webview.setWebViewClient(new WebViewClient()); //instantiate new
webviewclient
        webview.getSettings().setJavaScriptEnabled(true); //enable
javascript for this new webviewclient
        webview.loadUrl("http://www.google.com/";); //load web address
        }
} 

-----Original Message-----
From: android-beginners@googlegroups.com
[mailto:android-beginn...@googlegroups.com] On Behalf Of Christer Østergaard
Sent: Friday, September 04, 2009 2:10 AM
To: Android Beginners
Subject: [android-beginners] Re: HelloWebView - WebViewClient odd behaviour


Hi,

Thank you for your reply.

Your suggestion actually takes away the point of the HelloWebView tutorial,
in which we are shown how to intercept the actions and have more control
over the view by creating a sub-class of WebViewClient.

Anyways, of course, any input is appreciated, and actually, I do get the
same behavior when using WebViewClient!!! This strikes me as very odd,
because what we're basically doing is replacing default behaviour with
default behavirour, no?

Any suggestions?

Thanks in advance,
Christer

On 3 Sep., 21:06, "tinyang" <tiny...@earthlink.net> wrote:
> Hello Christer.
>
> Have you tried that line without the Hello?
>
> webview.setWebViewClient(new WebViewClient());
>
>

No virus found in this incoming message.
Checked by AVG - http://www.avg.com
Version: 8.0.169 / Virus Database: 270.13.71/2332 - Release Date: 9/3/2009
6:05 PM


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

Reply via email to