I am learning how to use Xcode (absolutely beginner), I have a problem while creating new swift files inside my project and relate them to the other files inside the same project. I am not a native english speaker, sorry if my english is not perfect.
So, I created a new swift file and write the code:
import UIKit class CardCollectionViewCell: UICollectionViewCell {
}
Then I go to to the storyboard, view, collection view, and cell, and try to establish that cell like a CardCollectionViewCell with the Identity inspector, with no problem. But when I try to use the assistant to change it form automatic to manual so I can select CardCollectionViewCell instead of automatic ViewController.swift there is no that option, only automatic can be choose.
I am stuck with this and being trying to figure it out for hours so any help would be appreciated. I arrived to this problem while trying to follow this tutorial: How To Build a Match Game - Lesson 4 (Custom Classes) from Chris Youtube Channel.
Hey @Thiago_King. Feel free to zip up your project, and send it over to me, and I will take a look. You can upload the file to a file sharing service like Box, and paste the link in here. Also, make sure to zip up the entire project folder, not just the Xcode file.
Hey @Thiago_King. Can you try manually opening CardCollectionViewCell through the assistant editor. I was able to do that in your project. @Tay5ive Can you please also try that?
I manually opened CardCollectionViewCell, then adding the editor on screen so I can use it with the storyboard side by side. Thanks so much for the help and for taking the time to check my project, I really appreciated it. Have a nice day!
@David_Ruvinskiy Thanks!, I am going well with Chris videos, struggling a little bit with delegates and protocols but is because this is all new for me, hopefully I will understand them better with some practice. A little question I have is about constraints, when I try to set them to 0, Xcode change them to default, and apparently is not the same, so I am using 1 instead, any way I can set them to 0?
Hey @Thiago_King i have the same problem, so what i do after i set the constraints is manually set them to 0 by clicking the contraints and going over to the trailing alignment constraint and manually putting the constant to 0. Hopefully that will help you.