Note that there are some explanatory texts on larger screens.

plurals
  1. POAndroid App Iframe a site
    text
    copied!<p>I was trying to make android app for my radio station. I want when user will open the app the site will load automatically. I was following this <a href="http://developer.android.com/guide/webapps/webview.html" rel="nofollow">tutorial</a> but when I tried to run the app it's showing this error "Unfortunately,Tarab Radio stop work " Here is my activity_main.xml</p> <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt; &lt;LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical"&gt; &lt;WebView android:id="@+id/webview" android:layout_width="fill_parent" android:layout_height="fill_parent" /&gt; &lt;/LinearLayout&gt; </code></pre> <p>&amp; MainActivity.java</p> <pre><code> package com.jibon.tarabradio; import android.os.Bundle; import android.annotation.SuppressLint; import android.app.Activity; import android.view.Menu; import android.webkit.WebView; public class MainActivity extends Activity { @SuppressLint("SetJavaScriptEnabled") @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); WebView webview; webview = (WebView) findViewById(R.id.webview); webview.getSettings().setJavaScriptEnabled(true); webview.loadUrl("http://hoicoimasti.com/radio/"); } @Override public boolean onCreateOptionsMenu(Menu menu) { // Inflate the menu; this adds items to the action bar if it is present. getMenuInflater().inflate(R.menu.main, menu); return true; } } </code></pre> <p>Any Idea where I did mistake. Thanks in advance.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload