Monday, August 2, 2010

[android-developers] creating a WebView in the top of a view

Hi,

I'm trying to do a fairly simple thing but i'm failing since 3 hours.

I have a WebView that i show with some pictures and html stored in
local sdcard. After the user clicks a button in my app, i want to show
the webview, and when he press the back button, i want to return to
the previous view (which is my main app view).

Can someone tell me how to do it? I tried this:

WebView webview = new WebView(this);
setContentView(webview);
webview.loadUrl(url);

However, when i press back, my app quits.

thanks in advance,

guich

--
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+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

No comments:

Post a Comment