Skip to content

iOS Lesson 4 Segued Screen only shows details of first cell #30

Answered by granwyntan
ndgsghdj asked this question in Q&A - iOS
Discussion options

You must be logged in to vote

So in your TableViewController.swift, have a variable to store the index, then in the didSelectRowAt() function, modify the index to be indexPath.

Then, you'll need to modify the index accordingly in your prepare(for segue:, sender:) override function.

update the text below // Send data here to modify the index variable in your DetailViewController.swift, which is now with the value of 0

Don't worry if you're still confused you can listen in next lesson as we'll be going through.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@granwyntan
Comment options

Answer selected by ndgsghdj
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants