[Newbie] Quitting App automatically
[Newbie] Quitting App automatically
- Subject: [Newbie] Quitting App automatically
- From: Andre Bonhote <email@hidden>
- Date: Wed, 23 Jun 2004 11:07:40 +0200
- Mail-followup-to: Cocoa Developers <email@hidden>
Hi!
First of all: I am new to this list and new to Cocoa, plus new to
(Objective) C. I coded quite a few thousand lines on *nix computers in
OO Perl. Currently, I am reading Aaron Hillegass' book "Cocoa
programming for Mac OS X". First chapter done :)
Now, I'd like to code a small app which opens a terminal window and
executes a console app in there. After the terminal has opened, I'd like
to quit the caller application. Later, I'd add some preference window to
let the user choose.
To learn how to quit an app automatically, I took Aaron's first example
(the neat random number generator) and added an "Exit" button. The first
step was to connect the button to the first responder
(NSApplication:terminate method). Then, I tried to implement a small
"exit" method which does the job - as it has to be done without getting
messages from the user.
I had a look at the NSApplication class, but I didn't find a way to call
the terminate: method. Everything I found in the internet was connected
to user interaction - that's not what I want.
I hope someone has a hint for me, maybe with a real world example. I
suppose it's very simple ... :-/
Thanks a lot in advance & HAND
Andri
--
Never laugh at live dragons.
-- Bilbo Baggins [J.R.R. Tolkien, "The Hobbit"]
_______________________________________________
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.