CoreData: "nil is not a valid persistent store" and can't save

  • Hi guys,

    The phenomenon was:
    1) make new document and then save it as one of three types (binary,
    SQL, MXL), the file is saved.
    2) open a file which is a custom-formatted file and then save it as
    like above, debug console shows "nil is not a valid persistent
    store", the file doesn't get saved.

    My managed object model has two entities: Department and Employ.
    Each managed object of those types is created by using
    insertNewObjectForEntityForName:inManagedObjectContext:.
    The managed object context passed as the second parameter is the one
    from [myDocument managedObjectContext].
    I don't override the method 'managedObjectContext'.

    I have a nib for displaying lists of the name of departments and of
    employees. The custom-formatted file seemed to be read properly
    because the lists showed the names as I expected.

    But when I tried to save it as one of the types, debug console showed
    "nil is not a valid persistent store", and nothing was saved.

    I must be missing something important. Any suggetions would be very
    appreciated.

    Thank you for reading this poor explanation.

    Norio Ota
previous month october 2007 next month
MTWTFSS
1 2 3 4 5 6 7
8 9 10 11 12 13 14
15 16 17 18 19 20 21
22 23 24 25 26 27 28
29 30 31        
Go to today