文档"Main.storyboard"被设置为"Main.storyboard".无法打开 [英] The document "Main.storyboard" could not be be opened
问题描述
我正在使用Git,我们两个人在一起编码.我拉出了我朋友的代码,运行了它,并按预期工作了.然后,我合并了我们的部分并清除了冲突(几乎所有冲突都在情节提要中).由于我已经进行了一段时间的合并过程,因此我对这些细节并不陌生. 但是,当我运行代码的合并版本时,出现错误:
I'm using Git and we are 2 people coding together. I pulled my friend's code, run it and it worked as it should be. Then I merged our parts and cleaned conflicts (almost all of them were in storyboard). Since i'm doing this merge process for a while, i'm not all stranger for these details. However, when i run the merged version of code, i get the error:
无法打开文档"Main.storyboard".手术 无法完成. (com.apple.InterfaceBuilder错误-1.)
The document "Main.storyboard" could not be opened. The operation couldn’t be completed. (com.apple.InterfaceBuilder error -1.)
我也不能以界面生成器的形式打开情节提要.当我尝试它时,我得到相同的错误.我阅读了有关此错误的以前的帖子,但是正如我提到的,合并之前,我可以在XCode中打开并运行两个版本的代码.因此,不存在字体或属性字符串问题.
I can't open storyboard as interface builder either. When i try it, I get the same error. I read previous post about this error but as I mentioned, I can open and run both versions of code in my XCode before merge. Thus, there is not a font or attributed string problem.
可能是什么问题?
推荐答案
解决了由svn
合并的conflicts
之后,我遇到了这个问题.
I got this issue, after I solve the conflicts
which is merged by svn
.
我只能看到我的storyboard
的源代码,我无法将我的storyboard
打开为interface builder
.所以,在我奋斗之后,
I could only see the source code of my storyboard
, I could not open my storyboard
as interface builder
. So, after my struggle,
1)我删除了storyboard
源代码中的顶部空格行
1)I delete the topside space line in my storyboard
source code
2)并关闭我的Xcode
和simulator
3)重新启动我的项目
3)restart my project
它变成常规的,哎呀,源代码上的空格会影响我们的storyboard
!
it becomes regular, oops, the space line on the source code will affect our storyboard
!
这篇关于文档"Main.storyboard"被设置为"Main.storyboard".无法打开的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!