Re: How to customize NSDocument's error message 'The document ... could not be opened'
Re: How to customize NSDocument's error message 'The document ... could not be opened'
- Subject: Re: How to customize NSDocument's error message 'The document ... could not be opened'
- From: John Timmer <email@hidden>
- Date: Mon, 19 Sep 2005 07:45:54 -0400
> John and mmalc, thanks for your answers. The problem
> is that neither of the methods
>
> presentError:modalForWindow:delegate:didPresentSelector:contextInfo:
> willPresentError:inError
>
> of my subclass of NSPersistentDocument gets called
> for the error alert "The document ... could not be
> opened." So overriding them as you suggest does not
> help.
>
> But using the debugger I found out that NSApplication's
> presentError: gets called, so I override
>
> - (NSError *)application:willPresentError:
>
> in my application's delegate. This works fine.
>
Sorry about that - I hadn't run into this issue yet, so thanks for warning
me. I guess it makes sense that when you don't successfully create a
document, it can't present an error.
JT
_______________________________________________
This mind intentionally left blank
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden