BUG总结

And never forget the universally useful tip: restart your computer and try again.


1、最近使用xcode的时候,常常出现这种错误,程序运行不起来。

提示:
Couldn't register com.buerguo.myCal with the bootstrap server. Error: unknown error code.
This generally means that another instance of this process was already running or is hung in the debugger.
解决方案:

重启模拟器就搞定了。

2、Expected selector for Objective-C method    and   Expected method body


I open up Xcode and I am presented with two errors in my AppDelegate.h file. One of these errors says Expected selector for Objective-C method and the other one is Expected method body. I googled these two errors and found nothing that could solve my case. I have tried restarting Xcode and as well as my computer. I have also tried "Cleaning" the project and still my problem is not resolved. What could this error be? Is it on my end? Or is this an Xcode bug? 

I have tried putting the curly braces where you instructed, no new erros show but the other ones still persist. I want to say this is a bug with XCode, and maybe have to disable the option to where I cannot run my target if I have an error

解决方案:

  把引起这个错误的文件删除,然后重新建新文件,在把代码写进去。


3、The run destination My Mac 64-bit is not valid for Running the scheme '******'.

The scheme '******' contains no buildables that can be built for the SDKs supported by the run destination My Mac 64-bit. Make sure your targets all specify SDKs that are supported by this version of Xcode.

How to change the SDK: 
1) Click on the project icon in the left hand panel. 
2) In the right hand panel that appears, select Build Settings » all. 
3) You'll see the option to change the SDK. Screenshot
4) 把Base SDK項改成ios 5.0

4、xcode一直显示waiting for XXX to launch,模拟器跑不起来

 Go to Product -> Edit Scheme and select the Run scheme on the lefthand side. Go to the info tab, and next to launch there will be two options (neither of them selected): 'Automatically' and 'Wait for XXXX.app to Launch'. Select the Automatically one and it should clear up your issue.

you will need to exit your simulator manually and then run.

Go into your ProjectName.xcodeproj/ directory and delete anything named with your userid. Re-open the project in xcode and all that will get recreated and it should work. At least it did for me.




你可能感兴趣的:(BUG总结)