Re: Cocoa/Obj-C Restart Computer
Re: Cocoa/Obj-C Restart Computer
- Subject: Re: Cocoa/Obj-C Restart Computer
- From: Steve Checkoway <email@hidden>
- Date: Fri, 30 Jul 2004 15:33:15 -0700
On Jul 30, 2004, at 3:02 PM, Shalev NessAiver wrote:
Hmmm, well the terminal command: "shutdown -r now" will do that. All
you need to do is call that from Objective-C. I don't remember how to
call terminal commands off the top of my head, but worst comes to
worst you can stick it in an applescript.
Try a "man shutdown" to see all the options and do a search on the
apple docs to see how to put a terminal command in a Cocoa app.
system("shutdown -r now");
- Steve
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.