When I run the code below, the method rowControllerAtIndex
of WKInterfaceTable
returns nil.
[self.outletTable setNumberOfRows:numberOfCategoriesToShow withRowType:@"rowTypeLabel"];
RowControllerTypeLabel *theRow = [self.outletTable rowControllerAtIndex:rowInTable];
What I've checked:
RowControllerTypeLabel
. Custom Class
of my label to my custom class RowControllerTypeLabel
. What am I missing?
I forgot to set the row controller's identifier rowTypeLabel
in the Attributes inspector.
I hope that this post will help others to find the problem in a shorter time than I needed.
To solve you have to set the row controller's identifier in the Attributes Inspector:
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.