Cocoa应用系统重新启动 [英] Cocoa app system restart
本文介绍了Cocoa应用系统重新启动的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
你知道从代码中强制重新启动Mac OS计算机的任何方法吗?我试着一个小的applescript代码没有结果。
Do you know any way to forcing restart an Mac OS computer from code? I tried an small applescript code without result. Applications ask for shutdown to the user so the user could stop the restarting procedure.
注意
推荐答案
这是一个通常的东西,想强制。如果用户愿意键入他们的密码并且是计算机的管理员;也许您可以运行
It's an usual thing to want to force. If the user is willing to type in their password and are an administrator of the computer; perhaps you can run
sudo reboot
。
这篇关于Cocoa应用系统重新启动的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文