Random notification sound

92 views
Skip to first unread message

J C

unread,
Jun 26, 2025, 12:25:07 PMJun 26
to automa...@googlegroups.com
Newbie and not a programmer.
Trying to get a random notification sound for my Google messages. Using the "File list" block with notification directory and variable "fileList" .
Then, variable set
Value--  fileList[random(#fileList)]

NotificationPath

Then Set ringtone (notification) to variable NotificationPath

Nothing changed.
 Log
06-26 09:09:50.463 I 7178@1: Flow beginning
06-26 09:09:50.463 I 7178@3: File list
06-26 09:09:50.486 I 7178@4: Variable set
06-26 09:09:50.487 I 7178@2: Ringtone set
06-26 09:09:50.492 I 7178@0: Stopped at end

Thanks

--

Regards,
John
520.307.2556
Message has been deleted
Message has been deleted

Henrik "The Developer" Lindqvist

unread,
Jun 27, 2025, 9:29:15 AMJun 27
to Automate for Android
That's used to be the correct way. This problem seems to be that ringtones can no longer be files, probably since the Dialer app can't access such.
To only alternative is to copy sound files to the Ringtones folder, then use the Ringtone pick block or Content query block to get an public content URI to them, see example flow:

J C

unread,
Jun 27, 2025, 9:52:49 AMJun 27
to automa...@googlegroups.com
Thanks so much.

--

Regards,


--
You received this message because you are subscribed to the Google Groups "Automate for Android" group.
To unsubscribe from this group and stop receiving emails from it, send an email to automate-use...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/automate-user/abb22c9d-855c-4401-b6a7-3c97767548ebn%40googlegroups.com.

J C

unread,
Jun 28, 2025, 2:01:18 PMJun 28
to automa...@googlegroups.com
Thanks again. 
I probably should study more of what android does.
I was wanting just a specific folder instead of all media files. Not sure what "content://media/external/audio/media" is or does.

--

Regards,
John Cohen
520.307.2556

On Fri, Jun 27, 2025, 6:29 AM Henrik "The Developer" Lindqvist <henrik.l...@gmail.com> wrote:
--

Henrik "The Developer" Lindqvist

unread,
Jun 28, 2025, 3:07:51 PMJun 28
to Automate for Android
I don't think that's how the media store works, it's not a mirror of the filesystem.
Reply all
Reply to author
Forward
0 new messages