Rename xcdatamodel file

前端 未结 10 2144
暖寄归人
暖寄归人 2020-12-05 00:55

What do in need to do to rename the .xcdatamodel file. Renaming .xcdatamodel filename, along with changing ...

NSURL *modelURL = [[NSBundle mainBundle] URLFo         


        
10条回答
  •  情话喂你
    2020-12-05 01:32

    There is a hidden file called .xccurrentversion which should be in the same location as your whatever.xcdatamodeld file. Inside there is a reference to your model which needs to be updated with the new name.

    In some cases, you'll have to remove the .xcdatamodeld file from the project and add it again to make it work.

提交回复
热议问题