找不到Google Play服务资源。编辑

时间:2014-04-12 15:46:27

标签: android google-play-services adview

我一直在搜索这样的3天,仍然没有找到任何解决方案。

我已经阅读了问题的答案:

还有更多...所以请不要将其称为副本,因为我没有在任何地方使用谷歌地图,所有上述问题都与地图有关。

如果有人真的想要帮助,我会与他分享我的完整项目+赏金。

04-12 20:49:17.570: E/GooglePlayServicesUtil(3661): The Google Play services resources were not found. Check your project configuration to ensure that the resources are included.
04-12 20:49:17.630: E/ActivityThread(3661): Activity com.xxx.xxx.XXXActivity has leaked ServiceConnection bbn@b3558278 that was originally bound here
04-12 20:49:17.630: E/ActivityThread(3661): android.app.ServiceConnectionLeaked: Activity com.xxx.xxx.XXXActivity has leaked ServiceConnection bbn@b3558278 that was originally bound here
04-12 20:49:17.630: E/ActivityThread(3661):     at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:936)
04-12 20:49:17.630: E/ActivityThread(3661):     at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:830)
04-12 20:49:17.630: E/ActivityThread(3661):     at android.app.ContextImpl.bindService(ContextImpl.java:1126)
04-12 20:49:17.630: E/ActivityThread(3661):     at android.content.ContextWrapper.bindService(ContextWrapper.java:370)
04-12 20:49:17.630: E/ActivityThread(3661):     at xo.b(SourceFile:90)
04-12 20:49:17.630: E/ActivityThread(3661):     at xo.a(SourceFile:118)
04-12 20:49:17.630: E/ActivityThread(3661):     at ud.d(SourceFile:88)
04-12 20:49:17.630: E/ActivityThread(3661):     at ud.b(SourceFile:129)
04-12 20:49:17.630: E/ActivityThread(3661):     at ua.a(SourceFile:239)
04-12 20:49:17.630: E/ActivityThread(3661):     at ua.a(SourceFile:176)
04-12 20:49:17.630: E/ActivityThread(3661):     at aas.a(SourceFile:118)
04-12 20:49:17.630: E/ActivityThread(3661):     at abz.run(SourceFile:14)
04-12 20:49:17.630: E/ActivityThread(3661):     at acb.run(SourceFile:30)
04-12 20:49:17.630: E/ActivityThread(3661):     at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1076)
04-12 20:49:17.630: E/ActivityThread(3661):     at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:569)
04-12 20:49:17.630: E/ActivityThread(3661):     at java.lang.Thread.run(Thread.java:856)
04-12 20:49:17.650: W/ResourceType(3661): getEntry failing because entryIndex 14 is beyond type entryCount 3
04-12 20:49:17.650: W/ResourceType(3661): Failure getting entry for 0x7f0b000e (t=10 e=14) in package 0 (error -2147483647)
04-12 20:49:17.650: E/GooglePlayServicesUtil(3661): The Google Play services resources were not found. Check your project configuration to ensure that the resources are included.
04-12 20:49:17.660: W/ResourceType(3661): getEntry failing because entryIndex 14 is beyond type entryCount 3
04-12 20:49:17.660: W/ResourceType(3661): Failure getting entry for 0x7f0b000e (t=10 e=14) in package 0 (error -2147483647)
04-12 20:49:17.660: E/GooglePlayServicesUtil(3661): The Google Play services resources were not found. Check your project configuration to ensure that the resources are included.
04-12 20:49:18.360: I/Ads(3661): Ad request cancelled.

XML文件:

<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    xmlns:ads="http://schemas.android.com/apk/res-auto"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    tools:context=".XXXActivity" >

    <ListView
        android:id="@+id/list"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_alignParentLeft="true"
        android:layout_alignParentTop="true"
        tools:listitem="@layout/abc" >
    </ListView>

    <com.google.android.gms.ads.AdView
        android:id="@+id/adView"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_alignParentBottom="true"
        android:layout_alignParentLeft="true"
        ads:adSize="BANNER"
        ads:adUnitId="<this_is_my_personal_id>" >
    </com.google.android.gms.ads.AdView>

</RelativeLayout>

代码:

// Look up the AdView as a resource and load a request.
AdRequest adRequest = new AdRequest.Builder().build();
adView = (AdView) findViewById(R.id.adView);
adView.loadAd(adRequest);

请帮忙。

----------- ---------------更新

清单:

    <application
        android:allowBackup="true"
        android:icon="@drawable/ic_launcher"
        android:label="@string/app_name"
        android:theme="@style/AppTheme" >
         <meta-data
            android:name="com.google.android.gms.version"
            android:value="@integer/google_play_services_version" />


 <activity
            android:name="com.google.android.gms.ads.AdActivity"
            android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize" />

....
....
....

0 个答案:

没有答案