The application I have made that does not have the option of move to SD card...
In my setting page I have no option for move app to sd card, but other application have it. Why is it like that? What is wrong I am doing?
And my application it looks like this
Developer Choice. Developers of Android apps need to explicitly make their apps available to move to the SD card using the “android:installLocation” attribute in the <manifest> element of their app. If they don't, the option to “Move to SD card” is grayed out.
From your Home screen, tap the Application screen icon. Find and tap Settings → Apps. Tap the On SD card tab. Select application, then tap Move to SD card.
Go to Settings > Apps and tap the app you want to move to your SD card. Next, under the Storage section, tap Move to SD Card. The button will be grayed out while the app moves, so don't interfere until it's done. If there's no Move to SD Card option, the app cannot be moved.
The Move to SD Card
option becomes disabled when you have
android:installLocation="internalOnly"
or if you have not set the android:installLocation
explicitly in your manifest file.
According to official documentation
By default, your application will be installed on the internal storage and cannot be installed on the external storage unless you define this attribute to be either "auto" or "preferExternal".
Add
android:installLocation="auto"
or
android:installLocation="preferExternal"
in your <manifest>
tag
Add property to your manifest
Tag
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
....
android:installLocation="auto">
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With