• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
NSPopUpMenuItem question
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSPopUpMenuItem question


  • Subject: NSPopUpMenuItem question
  • From: Matthew Kelley <email@hidden>
  • Date: Sat, 15 Jun 2002 14:20:54 -0500

I am new to objective-c programming and cocoa, and I was wonder what you would call a NSPopUpMenuItem. I know that in NSMatrices, one "item" is called a cell; I was wondering what in a list of NSPopUpMenuItem, you could call an "item". I've tried everything from PopUpMenuItem, to MenuItem, and most of the time I get a message of:
2002-06-15 14:11:08.087 Iln[2487] *** -[NSMenuItem selectedItem]: selector not recognized, or something along those lines.

Here is the code I am trying to work it into (it is a lame little app to see if I can make PopUpMenus preform conversions...):

- (IBAction)enterOp:(id)sender
{
if (yFlag) {
switch (operation) {
case centimetersToMeters:
X = .01 * X;
break;
}
}

Y = X;
yFlag = YES;

operation = [ [sender selectedPopUpMenuItem] tag];
enterFlag = YES;

[self displayX];
}

Any input and tips for a newbie programmer would be greatly appreciated as well :P.

(Sorry if this is a lame question, it has really been bugging me!)

- Matthew Kelley.
_______________________________________________
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.

  • Follow-Ups:
    • Re: NSPopUpMenuItem question
      • From: j o a r <email@hidden>
  • Prev by Date: Re: C question.
  • Next by Date: Properly capitalizing a path
  • Previous by thread: Re: C question.
  • Next by thread: Re: NSPopUpMenuItem question
  • Index(es):
    • Date
    • Thread