I control drag CollectionView from storyBoard to ViewController.h like this
#property (weak, nonatomic) IBOutlet UICollectionView *collectionView;
After Build, Xcode has an Apple LLVM 6.0 Error below.
file '/Applications/Xcode6-Beta5.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS8.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UICollectionViewLayout.h' has been modified since the precompiled header '/Users/alpha003/Library/Developer/Xcode/DerivedData/ModuleCache/1MBMXMEEES6H1/UIKit-14NGSGHI2IEK1.pcm' was built
It doesn't happened before. What is going on?
You should delete this file /Users/alpha003/Library/Developer/Xcode/DerivedData/ModuleCache/1MBMXMEEES6H1/UIKit-14NGSGHI2IEK1.pcm.
After you rebuild your project, the *.pcm files under ModuleCache directory will recreated in right way.
The reason is you have modified the system framework header files.
I just found out that the error only occur when Deployment Target is 7.0
Other Deployment Target like 6.0 or 7.1 worked just fine.
Although I still can't find out what's going on?
Related
Try to
#import <UIKit/UIKit.h>
And get error:
UIKit/UIKit.h file not found
What is it and how fix it ?))) Try to import Foundation - all ok )
Originally for macOS you could only use AppKit as an UI framwork, which is quite different from UIKit, so you couldn't reuse iOS code for macOS.
So you have to learn a much different framerwork with NSView base view instead of UIView and a lot of differences.
But then apple supported porting iOS apps to macOS. To do this you need to create an iOS app(if you don't have one) and turn on that option in the settings. Check out more at Running Your iOS Apps on macOS
You would still need to do a lot a work in making your app for macOS comfortable for users, but if you have no background in AppKit, probably it's still easier to go for UIKit
This is after I updated Yosemite, I think it is a Yosemite bug. Whenever I try to drag and drop from storyboard to .m or .h file, it will crash. Are there other people facing this problem? And is there any solution?
I have been experiencing this problem as well and pretty much the only thing you can do is wait until the next beta of Xcode 6 drops. There are a few solutions though.
Reinstall Mavericks and install the Xcode 6 beta on that, because the crashes aren't happening for me when I use the older OS.
The best workaround is to manually add your declaration on your header and implementation file. Then it should be OK if you drag from storyboard or nib to your declaration.
I created a tabbed application with xCode 5.01, recently downloaded from Apple, and put nothing else in it. It runs fine on the simulator, but when I try to run it on my iPhone 4S, which has OS6 on it, the build fails with these errors:
UIKit/UIKit.h is not found.
The Prefix.pch file is not found.
I looked everywhere and changed the deployment target to 6.0, but it doesn't solve the issue. What's going on?
EDIT: also, following an advice, I deleted the UIKit framework, but when I tried to re-add it (as per the advice) it turns out it's not there.
EDIT 2: Reinstalling xCode solved the issue. Go figure.
Reinstall XCode 5, it is still quite buggy, also when renaming folders, this can cause corrupt data structure inside the project file.
I installed the newly released phonegap(cordova) version 2.1.0 for IOS app development, and by default under Classes dir, both AppDelegate and MainViewController(containing view functions like webViewDidFinishLoad,webViewDidStartLoad,etc.) interface and implementation files came. Can i remove the MainViewController files and use only AppDelegate files for everything, like it used to be in phonegap 1.3.
Any help is appreciated.
Thanks
I wrote a program in the 3.2 SDK. I just upgraded to the new 4.2 SDK today. I can run the application fine in the 3.2 simulator. When I switch to the 4.2 simulator, the application crashes right after launching. I get the following error:
"Failed to load NSMainNibFile MainWindow"
I'm not understanding how this runs fine with 3.2 and not 4.2. Any suggestions would be much appreciated.
I had this exact thing happen to me. I
traced it to a bunch of missing Nib
files Target > [App Name] > Copy
Bundle resources. The MainWindow.xib
file was missing in this directory
along with a bunch of other files. I
deleted all the nib files from my
Resources directory (only the
references) and then added the
existing files back and everything
started working again. It definitely
looks like an XCode bug.
from - http://www.iphonedevsdk.com/forum/iphone-sdk-development/4958-failed-load-nsmainnibfile-mainwindow.html