我正在创建一个简单的应用,可以在按下按钮时播放广告。虽然当我尝试初始化Google移动广告SDK时,即使我已经完成Google提供的指南中的每一步,它也会失败。
<application android:allowBackup="true" android:icon="@mipmap/ic_launcher" android:label="@string/app_name" android:roundIcon="@mipmap/ic_launcher_round" android:supportsRtl="true" android:theme="@style/AppTheme" tools:ignore="GoogleAppIndexingWarning"> <meta-data android:name="com.google.android.gms.ads.Application_id" android:value="ca-app-pub-################~##########"/> <activity android:name=".MainActivity"> <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> </intent-filter> </activity> </application>
当我尝试运行应用程序时,我得到了这个
****************************************************************************** * The Google Mobile Ads SDK was initialized incorrectly. AdMob publishers * * should follow the instructions here: Link to add a valid * * App ID inside the AndroidManifest. Google Ad Manager publishers should * * follow instructions here: Link. * ****************************************************************************** at com.google.android.gms.internal.ads.zzabg.attachInfo(Unknown Source:16) at com.google.android.gms.ads.MobileAdsInitProvider.attachInfo(Unknown Source:3) at android.app.ActivityThread.installProvider(ActivityThread.java:6724) ... 10 more
慕工程0101907
相关分类