Show system alert or notification from Swift script -


i want show system alert or notification swift script. example, if there more 30 files in desktop folder, want see kind of notifications. how can it?

to send local notification, think have use this:

func shownotification() -> void {     var notification = nsusernotification()     notification.title = "test swift"     notification.informativetext = "the body of swift notification"     notification.soundname = nsusernotificationdefaultsoundname     nsusernotificationcenter.default.deliver(notification) } 

there detailed tutorial here


Comments

Popular posts from this blog

javascript - Create a stacked percentage column -

Optimising Firebase database by automatically overwriting data -

javascript - Angular UI-Grid customTemplate directive causing rows to load slowly/? -