在 cocoa 中保存文件
我确信这是一个很容易回答的问题,但我对可可还是新手。我需要保存我的应用程序数据。该应用程序有 4 个文本字段,每个字段都需要保存到一个文件中。然后,当您打开文件时,它需要知道哪个字段中有什么内容。我真的被这个问题困扰了。另外,我确实知道如何使用保存面板。
I'm sure this is a really easy to answer question but I'm still new to cocoa. I need to save my applications data. The app has 4 text fields and each field needs to be saved into one file. Then when you open the file it needs to know what goes in what field. I'm really stuck with this. Also, I do know how to use the save panel.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
一种方便的方法是使用 PLists:
用于反序列化:
A convenient way would be to use PLists:
For deserialization: