After successfully implementing the MFMailComposeViewController in my app, run it in the simulator and my iPhone, where it still works fine, it just crashed.
I get 5 MFMailComposeViewController.h issues: Cannot find protocol declaration, Expected identifier or '(', etc,...
My Controller header includes:
MessageUI/MessageUI.h
MessageUI/MFMailComposeViewController.h
and conforms to protocol:
#interface DetallViewController : UIViewController < UIActionSheetDelegate,
MFMailComposeViewControllerDelegate>
I've tried to:
1) remove and add the framework
2) Restart the device and Xcode as suggested in many posts
3) Create a separate controller to handle MFMailComposeViewController
After 3 days with this issue I'm completely stuck on this. As you can imagine, any help would be appreciate.
I would think this is a kind of reference issue since it appears whether the framework is selected or not.
Thanks in advance
Just to anybody it may help, I finally found the issue:
A missing #end in an imported header.
Thanks to everybody for the efforts.
Related
I'm trying to build a project that I downloaded from git and I got some errors in the Xcode beta 9.
I noticed that there are some things that are deprecated like ARWorldTrackingSessionConfiguration so I changed them and they were fixed. But I get an error that I can't fix, this is the part from the code:
matrix_float4x4 projectionMatrix = [frame.camera projectionMatrixWithViewportSize: nativeSize
orientation:[[UIApplication sharedApplication] statusBarOrientation]
zNear:(CGFloat)unityCameraNearZ
zFar:(CGFloat)unityCameraFarZ];
I could not fix this and I don't know what to do.
the error for that is this:
No visible #interface for 'ARCamera' declares the selector 'projectionMatrixWithViewportSize:orientation:zNear:zFar
Hope you can help me with this issue?
Thank you.
First of all you should update your XCode from beta to a stable version.
As for
No visible #interface for 'ARCamera' declares the selector 'projectionMatrixWithViewportSize:orientation:zNear:zFar
Here is official Apple documentation about ARCamera class which shows that there is no method projectionMatrixWithViewportSize:orientation:zNear:zFar and it's most possibly was changed to projectionMatrixForOrientation:viewportSize:zNear:zFar:. Signatures of this two methods requires the same parameters, so it won't be problem to replace the old method with a new one.
I am writing a subclass for NSOperation with swift. However, I met a strange problem.
class Downloader : NSOperation, NSURLSessionDelegate, NSURLSessionDownloadDelegate{}
When I add "NSURLSessionDownloadDelegate", it will show an error:"Type 'Downloader'does not conform to protocol 'NSURLSessionDownloadDelegate' "
When I delete it, every thing is Ok.
Do you know WHY?
Thanks, advance!
According to apple docs https://developer.apple.com/library/prerelease/ios/documentation/Foundation/Reference/NSURLSessionDownloadDelegate_protocol/index.html
implementing
URLSession:downloadTask:didFinishDownloadingToURL:
is necessary,
Please make sure that you have implemented it.
This is my first time being on this forum. It's nice to be here and i really want to thank you all for the educational lessons you are giving!
So i am suffering from this issue :
i am using Xcode 7 and i did try with the latest Xcode of yosemite(6.4 version) and it seems i cannot establish an outlet connection via the old ctrl and drag method to connect a UIImageView with the ViewController. i did search the net a bit and i found some "solutions" of doing a reference to the header file but it didn't work. Did this method got removed and if yes how are we connecting now an element with the ViewController? is something wrong with my Xcode and if yes how can i fix it?
really appreciate your help!
First of all create outlet object
than go to storyboard or xib.
right click on file's owner (yellow box on top of xib).
you get all the outlet than click on circle right side of your outlet and map with UI by dragging the line.
hope this help you.
in this method you have to create outlet manually.
So yeah i did manage to fix the issue. It appears there is a bug with swift and Xcode and i can tell it happens in all Xcode version 6 and up including Xcode 7. I don't know what exactly occurs this bug and i can't really link an element from scoreboard with ViewController via the simple ctrl drag and drop method but in order to fix i had to reimplent the tableView and reconfigure my elements. this did the trick and i was able to just ctrl drag and drop. if someone knows what occurs this issue please comment!!
thanks
im compiling my app , which is working great and i wanted to ask you 2 questions
1. im getting about 14 warnings like that
no '-addCategory' method found
which i know how to solve but even after i cleaned everything added the function to the header file and compile again it's still there i cant get rid of it.
2. im pretty new in coding and the code is not GREAT but it's ok how do i know apple will accept it ?
thank you very much !!
Declare that method in .h file
Implement that method in .m [implementor of .h] file .with the same signature.
Clean in once.
And try..
It should work..!
Can anyone please help me to solve the following error:
Error cannot find interface declaration for 'NSManagedObject', superclass of
Try
#import <CoreData/CoreData.h>
Are you missing an include statement?
Are you subclassing NSManagedObject? If so, go here in Apple's documentation and scroll to Xcode Generated Subclasses. They give you instructions to have Xcode generate class files from your data model.
A suggestion: Core Data is rather difficult, and you should be comfortable with iPhone development before you start working with it.
import CoreData to your xxx-Bridging-Header.h will make sense.