you also need to add webviewclient and webchromeclient On Feb 9, 10:45 pm, Sandeep Phansekar <sandeep.phanse...@gmail.com> wrote: > add following in your *manifest.xml* file > <uses-permission android:name=*"android.permission.INTERNET"* /> > -- > Regards > Sandeep > > On Wed, Feb 10, 2010 at 8:51 AM, Breezy <mbre...@gmail.com> wrote: > > Does your layout XML look like this? > > > <LinearLayout xmlns:android="http://schemas.android.com/apk/res/ > > android" > > android:layout_width="fill_parent" > > android:layout_height="fill_parent" > > android:orientation="vertical"> > > > <WebView > > android:id="@+id/webview" > > android:layout_width="fill_parent" > > android:layout_height="fill_parent" > > android:scrollbars="none" > > /> > > > </LinearLayout> > > > On Feb 9, 8:59 pm, Saurabh Lodha <saurabh.comp...@gmail.com> wrote: > > > Hi, > > > > I am using the following code to display a WebView in my Android 2.x > > > application. However this does not display anything on screen. > > > > public class WebViewTest extends Activity { > > > WebView webview; > > > String TAG = "WebViewTest"; > > > > /** Called when the activity is first created. */ > > > @Override > > > public void onCreate(Bundle savedInstanceState) { > > > try { > > > super.onCreate(savedInstanceState); > > > setContentView(R.layout.main); > > > > webview = (WebView) findViewById(R.id.webview); > > > webview.getSettings().setJavaScriptEnabled(true); > > > webview.loadUrl("http://www.google.com"); > > > > } catch (Exception e) { > > > Log.w("TAG", e.getMessage()); > > > } > > > } > > > > } > > > > Any ideas? > > > > Thanks, > > > Saurabh > > > -- > > 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<android-developers%2bunsubscr...@googlegroups.com> > > For more options, visit this group at > >http://groups.google.com/group/android-developers?hl=en
-- 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