views:

26

answers:

1

Hi all,

i have a Problem wich drives me crazy... I want to "write" a Cocoa CoreData Application, write is not the exact term, because the Application should be created with Bindings.

It was no Problem to create a Document-Based Application, it works fine. But i want a Non-Document-Based Application, so I thought "Do the same like at the Document-Based App", but if I do so the Application do not start. XCodes' GDB says:

2010-07-14 11:02:39.894 nonDocBased[1242:a0f] An uncaught exception was raised
2010-07-14 11:02:39.899 nonDocBased[1242:a0f] [<NSApplication 0x100408e90> valueForUndefinedKey:]: this class is not key value coding-compliant for the key managedObjectContext.
2010-07-14 11:02:39.902 nonDocBased[1242:a0f] *** Terminating app due to uncaught exception 'NSUnknownKeyException', reason: '[<NSApplication 0x100408e90> valueForUndefinedKey:]: this class is not key value coding-compliant for the key managedObjectContext.'

So I googled on this, but found nothing helpful (or probably I was just too unexperienced... ). But I found a Tutorial (http://www.raywenderlich.com/934/core-data-tutorial-getting-started) and tried it without Bindings but this neither works.

So my Question is how do I create a Non-Document-Based Application using Core Data?

Here's my Code, the Password is stackoverflow.

Thanks for any Ideas... Dennis

+2  A: 

Bind the NSArrayController managedObjectContext to your AppDelegate not to Files's owner.

Martin Brugger
Oh no... What a stupid error. Thank you very much. It's totaly logic.And this stupid error drives me crazy for some days :-(Thank you... Dennis
Dennis S.