1

I need to set custom sound for only my application. I've assigned a custom ringtone from my storage to be used in notifications.

What did I try...

(NotificationChannel) channel.setSound(Uri.parse("MY_PATH"), audio_atrr);
(NotificationCompact.Builder) mBuilder.setSound(Uri.parse("MY_PATH"));
(Notification) mNotification.sound = Uri.parse("MY_PATH");

It's useless for me, my device always plays the default sound when a notification is coming. what can i do?

  • did you checked this - [click here](https://stackoverflow.com/a/71159936/14682570) and add some info like what Android version you tested,notifcation from firebase or locally. – Dev007 Nov 12 '22 at 12:50
  • Yes but my situation is set ringtone from application – Urvish Vocsy Nov 14 '22 at 05:10

0 Answers0