Zev Farkas

Zev Farkas

  • NA
  • 6
  • 580

changing ring mode

Aug 2 2018 6:34 PM
Hi -
 
I'm trying to change the ring mode of my phone using code like:
 
am.setRingerMode(AudioManager.RINGER_MODE_SILENT);
am.setRingerMode(AudioManager.RINGER_MODE_NORMAL);
am.setRingerMode(AudioManager.RINGER_MODE_VIBRATE);
 
(one at a time, of course...)
 
normal and vibrate seem to work OK, but silent does not.
 
I tried it using 0, 2 and 1 instead of AudioManager.RINGER_MODE_SILENT, AudioManager.RINGER_MODE_NORMAL and AudioManager.RINGER_MODE_VIBRATE, respectively, and got the same results - normal and vibrate work, but silent doesn't.
 
Any idea what I'm doing wrong here?
 
Thanks, and sorry for the sloppy typesetting... :)