Can an Apple Watch vibrate a local notification only and not play a sound?

I would like to schedule a local phone notification. When the phone is locked and the watch is sleepy, I want the notification to vibrate the watch but not play a sound. Is it possible? My code below works on iphone to schedule notification, but doesn’t know how to suppress sound when playing on watch.

UILocalNotification *notification = [[UILocalNotification alloc] init];
        notification.fireDate = [[NSDate date] dateByAddingTimeInterval:60];
        notification.alertTitle = [NSString stringWithFormat:@"Hi # %d", i];
        notification.alertBody = @"Hello!";
        notification.soundName = UILocalNotificationDefaultSoundName;

        [[UIApplication sharedApplication] scheduleLocalNotification:notification];
+1
source share
1 answer

You can not set a sound name or use sounds in notification settings. Then you can make your own vibration behavior, if not already.

0
source

Source: https://habr.com/ru/post/1625017/


All Articles