Skip navigation.
 
mlRe: Extending a save panel
FROM : Shaun Wexler
DATE : Thu Dec 16 23:26:57 2004

On Dec 16, 2004, at 2:00 PM, Matt Mashyna wrote:

> I want to add popup button to my save panel so that I can save file in
> different formats. When the document is created I don't know what
> format the user will want to save it in. So, I want to allow them to
> choose from the pop up.
>
> So, I added an NSPopUpButton to the panel using prepareSavePanel. I
> thought I could use setTarget and SetAction to catch the changes in
> the pop up. It builds OK and the pop up is there but when I used
> SetAction the pop up is disabled, otherwise it looks OK.
>
> I think maybe I'm going about this all wrong. Can someone tell me the
> right way to do it ? Here some snippets from MyDocument.m:
>
>     [saveModeButton setTarget: self];
>     SEL tellMeAboutIt = @selector(setDSCFileMode);
>     [saveModeButton setAction: tellMeAboutIt];


Action methods take an id argument, the sender.  Your selector is
missing the colon...
--
Shaun Wexler
MacFOH
http://www.macfoh.com

Related mailsAuthorDate
mlExtending a save panel Matt Mashyna Dec 16, 23:00
mlRe: Extending a save panel Shaun Wexler Dec 16, 23:26
mlRe: Extending a save panel Matt Mashyna Dec 17, 00:56