Note that there are some explanatory texts on larger screens.

plurals
  1. POAdmob implementation Error
    text
    copied!<p>I got a Problem with implementing Admob into an App.</p> <p>This is my main.xml:</p> <blockquote> <pre><code>&lt;LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:ads="http://schemas.android.com/apk/lib/com.google.ads" android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical" &gt; &lt;TextView android:id="@+id/textView1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Large Text" android:textAppearance="?android:attr/textAppearanceLarge" /&gt; &lt;LinearLayout android:id="@+id/linearLayout1" android:layout_width="fill_parent" android:layout_height="wrap_content" android:orientation="vertical" &gt; &lt;/LinearLayout&gt; &lt;/LinearLayout&gt; </code></pre> </blockquote> <p>and this is my Manifest: </p> <blockquote> <pre><code>&lt;manifest xmlns:android="http://schemas.android.com/apk/res/android" package="de.ollidiemaus.testmob" android:versionCode="1" android:versionName="1.0" &gt; &lt;uses-sdk android:minSdkVersion="7" /&gt; &lt;application android:icon="@drawable/ic_launcher" android:label="@string/app_name" &gt; &lt;activity android:label="@string/app_name" android:name=".TestAdmobActivity" &gt; &lt;intent-filter &gt; &lt;action android:name="android.intent.action.MAIN" /&gt; &lt;category android:name="android.intent.category.LAUNCHER" /&gt; &lt;/intent-filter&gt; &lt;/activity&gt; &lt;activity android:name="com.google.ads.AdActivity" android:configChanges="keyboard|keyboardHidden|orientation"/&gt; &lt;/application&gt; &lt;uses-permission android:name="android.permission.INTERNET"/&gt; &lt;uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/&gt; &lt;/manifest&gt; </code></pre> </blockquote> <p>And finaly this is my Activity:</p> <blockquote> <pre><code>public class TestAdmobActivity extends Activity { private AdView adView; /** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); // Create the adView adView = new AdView(this, AdSize.BANNER, "a14ead58dc2a456"); // Lookup your LinearLayout assuming it’s been given // the attribute android:id="@+id/mainLayout" LinearLayout layout = (LinearLayout)findViewById(R.id.linearLayout1); // Add the adView to it layout.addView(adView); // Initiate a generic request to load it with an ad adView.loadAd(new AdRequest());} @Override public void onDestroy() { adView.destroy(); super.onDestroy(); }} </code></pre> </blockquote> <p>Now when i'll start the app in the AdView is an error called: "you must have AdActivity declared in AndroidManifest.xml with configChanges."</p> <p>I used Android 4.0 so above 3.2 but it is not working. I hope anyone could help me.</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