티스토리 뷰

개발/IOS

could not dequeue a view of kind

aihtnyc_h 2024. 1. 3. 23:06
728x90
반응형
SMALL

Thread 1: "could not dequeue a view of kind: UICollectionElementKindCell with identifier SpeedTypeCell - must register a nib or a class for the identifier or connect a prototype cell in a storyboard"

        self.speedCollectionView.registerCell(type: FilterTypeCell.self)
        self.speedCollectionView.delegate = self
        self.speedCollectionView.dataSource = self

type 부분을 다른 Cell을 호출해서 발생한 문제..!🥲
        self.speedCollectionView.registerCell(type: SpeedTypeCell.self)
        self.speedCollectionView.delegate = self
        self.speedCollectionView.dataSource = self

SpeedTypeCell을 연결하지 않아서 발생한 문제
변경해서 수정해주니 가능!

컨트롤러뷰.registerCell(type:연결할 UI Cell)
컨트롤러와 UI를 연결해주는 코드!!

728x90
반응형
LIST
반응형
250x250
공지사항
최근에 올라온 글
최근에 달린 댓글
Total
Today
Yesterday
«   2025/11   »
1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30
글 보관함