• 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
Re: NSMutableDictionary Error
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSMutableDictionary Error


  • Subject: Re: NSMutableDictionary Error
  • From: mw <email@hidden>
  • Date: Sat, 18 Jan 2003 13:22:42 -0500

On 1/18/03 1:08 PM, "Seth Willits" <email@hidden> wrote:

> When compiling, the compiler gives me the error that the
> NSMutableDictionary class doesn't respond to the setObject:forKey
> message. How can this be? It's clearly documented.
>
>
> NSMutableDictionary * attribs = [NSMutableDictionary dictionary];
>
> [attribs setObject:[NSFont fontWithName:@"Times" size:36]
> forkey:NSFontAttributeName];
>
> PB 2.1 & OS X 10.2.3
>
> Seth Willits

Well, if your code is copied directly from your application, then the
problem is you are calling setObject:forkey when the method is
setObject:forKey:. Notice how Cocoa is case-sensitive?

Mw
_______________________________________________
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.

References: 
 >NSMutableDictionary Error (From: Seth Willits <email@hidden>)

  • Prev by Date: Re: NSWindow
  • Next by Date: Re: AppKit deadlock
  • Previous by thread: NSMutableDictionary Error
  • Next by thread: Re: NSMutableDictionary Error
  • Index(es):
    • Date
    • Thread