我已經看到關於堆棧溢出問題的許多問題。我有類似的問題,像下面這個問題,但情況稍有變化。
點擊here!
首先我使用Eclipse。
其次我有權限在「應用程序標籤之外」的正確位置。我對internet和access_network_state也有權限。
我不知道問題出在哪裏。你的幫助將被視爲。
這是我的清單代碼。權限被拒絕可能缺少互聯網許可。在添加廣告網絡時強制關閉錯誤
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.test"
android:versionCode="1"
android:versionName="1.0" android:installLocation="auto">
<uses-sdk
android:minSdkVersion="8"
android:targetSdkVersion="18" />
<uses-permission android:name="android.permission.WAKE_LOCK"/>
<uses-permission android:name="android.persmission.WRITE_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.persmission.READ_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.persmission.SET_WALLPAPER" />
<uses-permission android:name="android.persmission.READ_PHONE_STATE" />
<uses-permission android:name="android.persmission.ACCESS_WIFI_STATE" />
<uses-permission android:name="android.persmission.ACCESS_COARSE_LOCATION" />
<uses-permission android:name="android.persmission.ACCESS_FINE_LOCATION" />
<application
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:theme="@style/AppTheme" >
<activity
android:name="com.example.test.MainMenuActivity"
android:label="@string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name="com.example.test.GamePlayActivity"
android:screenOrientation="portrait">
</activity>
<!-- Heyzap Ads Start -->
<activity
android:name="com.heyzap.sdk.ads.HeyzapInterstitialActivity"
android:configChanges="keyboardHidden|orientation|screenSize|smallestScreenSize" />
<receiver android:name="com.heyzap.sdk.ads.PackageAddedReceiver" >
<intent-filter>
<data android:scheme="package" />
<action android:name="android.intent.action.PACKAGE_ADDED" />
</intent-filter>
</receiver>
<!-- Heyzap Ads Ends -->
</application>
下面是這個應用
05-10 12:20:40.058: E/AndroidRuntime(8535): FATAL EXCEPTION: Thread-8341 05-10 12:20:40.058: E/AndroidRuntime(8535): java.lang.SecurityException: ConnectivityService: Neither user 10098 nor current process has android.permission.ACCESS_NETWORK_STATE. 05-10 12:20:40.058: E/AndroidRuntime(8535): at android.os.Parcel.readException(Parcel.java:1425) 05-10 12:20:40.058: E/AndroidRuntime(8535): at android.os.Parcel.readException(Parcel.java:1379) 05-10 12:20:40.058: E/AndroidRuntime(8535): at android.net.IConnectivityManager$Stub$Proxy.getActiveNetworkInfo(IConnectivityManager.java:680) 05-10 12:20:40.058: E/AndroidRuntime(8535): at android.net.ConnectivityManager.getActiveNetworkInfo(ConnectivityManager.java:476) 05-10 12:20:40.058: E/AndroidRuntime(8535): at com.heyzap.internal.Connectivity.connectionType(Unknown Source) 05-10 12:20:40.058: E/AndroidRuntime(8535): at com.heyzap.sdk.ads.FetchRequest.getParams(Unknown Source) 05-10 12:20:40.058: E/AndroidRuntime(8535): at com.heyzap.sdk.ads.FetchManager.fetch(Unknown Source) 05-10 12:20:40.058: E/AndroidRuntime(8535): at com.heyzap.sdk.ads.InterstitialAd.fetch(Unknown Source) 05-10 12:20:40.058: E/AndroidRuntime(8535): at com.heyzap.sdk.ads.InterstitialAd.fetch(Unknown Source) 05-10 12:20:40.058: E/AndroidRuntime(8535): at com.heyzap.sdk.ads.HeyzapAds$1.run(Unknown Source) 05-10 12:20:40.058: E/AndroidRuntime(8535): at java.lang.Thread.run(Thread.java:856)
發佈您的清單和logcat請 – Lal
我很抱歉它現在不可用,但會盡快做到這一點。 但鏈接中的問題與我相信的相同。 –