69808

Android Namespace Missing

Question:

I have the following in my Android manifest and I am getting an error with the following:

<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"> <group gid="media_rw" /> </uses-permission>

It is saying "Attribute is missing the Android namespace prefix" The exact same file before I modified it was working just fine. My full manifest is below:

<?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.example.test12" android:versionCode="1" android:versionName="1.0" > <!-- uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"></uses-permission--> <uses-permission android:name="android.permission.WAKE_LOCK"></uses-permission> <uses-permission android:name="android.permission.INTERNET"></uses-permission> <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"></uses-permission> <uses-permission android:name="android.permission.ACCESS_WIFI_STATE"></uses-permission> <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"> <group gid="media_rw" /> </uses-permission> <uses-sdk android:minSdkVersion="10" android:targetSdkVersion="10" /> <application android:allowBackup="true" android:icon="@drawable/ic_launcher" android:label="@string/app_name" android:theme="@style/AppTheme" > <activity android:name="com.example.test12.MainActivity" android:label="@string/app_name" android:screenOrientation="portrait" > <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> </intent-filter> </activity> <activity android:name=".TestityTest" android:screenOrientation="portrait" /> </application> <application android:name="GlobalObjects" android:label="@string/app_name" /> </manifest>

Answer1:

If you check the <a href="http://developer.android.com/guide/topics/manifest/manifest-intro.html" rel="nofollow">AppManifest documentation</a>, there is no such thing as <group gid="media_rw" />.

I know that someone use <group gid="media_rw" /> to allow the write access to SD card on Kitkat, but it applies to the <strong>Android System</strong>, not to individual apps.

You can find some related discussion here: <a href="http://www.chainfire.eu/articles/113/Is_Google_blocking_apps_writing_to_SD_cards_/" rel="nofollow">Is Google blocking apps writing to SD cards ?</a>.

Answer2:

It turns out that I had to open the file in another editor save it and then clean and build the project again. I have no idea why it was the case.

Recommend

  • Hide/show the selected option on a secondary select
  • PHP Replace multidimensional array keys
  • Text manipulation in Spark and Scala
  • How to sum similar element of an array of structure in vb.net?
  • App not compatible with Nexus 7 and Acer Iconia a210
  • Gradle Build Failure java.io.IOException: The output jar is empty
  • Kotlin fails to compile a library
  • Execution failed for task : 'app.transformClassesWithDesugarForDebug'. after importing pro
  • How to use Android's AppCompat theming application-wide?
  • Dependency commons-logging:commons-logging:1.2 is ignored for debug as it may be conflicting with th
  • Ionic App On Android Tablet
  • How to convert NAnt function “path::combine(path1, path2)” to MSBuild?
  • Savon soap body problem
  • Android Studio cannot find resources when building for device with version > 5.0
  • Toolbar shifts up, when soft keyboard appears
  • Loop animation drawable
  • Gray line inside cardview :)?
  • Android Lock Screen C# .NET Replica
  • Wrapping text in spinner android
  • XSD with multi occurrences unordered
  • Running jasmine tests for a component with NgZone dependency
  • How to resolve permission denied maybe missing internet permission?
  • Splash Screen will not display
  • WPF Template Binding in ToggleButton UserControl
  • where do I find the xml.dom python package for the python-2.6.0-8.9.28 and I have a suse/x86_64 vers
  • Spring boot 2.0.0.M4 required a bean named 'entityManagerFactory' that could not be found
  • Read text file that is not in the main package in a runnable jar
  • Roxygen error “Skipping invalid path”
  • JBoss External Properties Files in Classpath
  • Access variable of ScriptContext using Nashorn JavaScript Engine (Java 8)
  • How Lists (specifically, RecyclerView with CardViews) in Android work
  • Code in Job's Script Block after Start-Process Does not Execute
  • Android - Material Design - NavigationView - How to put vertical scroll?
  • Why Encoding.ASCII != ASCIIEncoding.Default in C#?
  • Jquery UI tool tip close icon
  • Pass value from viewmodel to script in zk
  • Encrypt data by using a public key in c# and decrypt data by using a private key in php
  • SSO with signing and signature validation doesn't work
  • Deserializing XML into class C#
  • costura.fody for a dll that references another dll