How to use status folder for WhatsApp status saver app in android 11 storage

0 votes
I  made a WhatsApp status saver app.

 But in android 11, Google introduced scoped storage, I'm not getting status of the user.

 For that I have used MANAGE_EXTERNAL_STORAGE but with this I can't publish the app in Google play.

How to do that ?
Jun 1, 2022 in Others by polo
• 1,480 points
1,570 views

1 answer to this question.

+1 vote

You can request the user to give permission to the WhatsApp status storage folder.

private void checkWhatsAppPermission(){
    // Choose a directory using the system's file picker.
    Intent intent = new Intent(Intent.ACTION_OPEN_DOCUMENT_TREE);
    // Optionally, specify a URI for the directory that should be opened in
    // the system file picker when it loads.

    Uri wa_status_uri = Uri.parse("content://com.android.externalstorage.documents/tree/primary%3AAndroid%2Fmedia/document/primary%3AAndroid%2Fmedia%2Fcom.whatsapp%2FWhatsApp%2FMedia%2F.Statuses");
    intent.putExtra(DocumentsContract.EXTRA_INITIAL_URI, wa_status_uri);
    startActivityForResult(intent, 10001);
answered Jun 1, 2022 by nisha
• 2,190 points

Related Questions In Others

0 votes
1 answer

How to use Card Widget in Flutter App?

Hi@akhtar, A card is a sheet of material used to ...READ MORE

answered Aug 26, 2020 in Others by MD
• 95,420 points
576 views
0 votes
1 answer

How to use ListTile class in Flutter App?

Hi@akhtar, A list tile contains one to three ...READ MORE

answered Aug 26, 2020 in Others by MD
• 95,420 points
1,010 views
0 votes
1 answer

How to use for loop in Flutter?

Hi@akhtar, As the name suggests Dart for in ...READ MORE

answered Sep 3, 2020 in Others by MD
• 95,420 points
17,456 views
+1 vote
1 answer

How to use VBA in Excel for Google Search?

Try this: Private Const LicenseRegistration As String = ...READ MORE

answered Oct 7, 2022 in Others by narikkadan
• 50,840 points
314 views
0 votes
1 answer
0 votes
0 answers
–1 vote
1 answer

"Default Activity Not Found" on Android Studio upgrade

If you see that ERROR occurrence after ...READ MORE

answered Feb 11, 2022 in Others by Soham
• 9,700 points
457 views
0 votes
1 answer

Execution Failed for task :app:compileDebugJavaWithJavac in Android Studio

In Android Studio 3.1, you can see ...READ MORE

answered Feb 17, 2022 in Java by Aditya
• 7,660 points
6,109 views
0 votes
1 answer

How to open YouTube video link in android app?

The below code will do that: Intent intent ...READ MORE

answered Jun 1, 2022 in Others by nisha
• 2,190 points
764 views
0 votes
1 answer

How to prepare an APK for the Amazon Android App Store

you should use zipalign during every build, ...READ MORE

answered Jun 1, 2022 in Others by nisha
• 2,190 points
134 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP