How present the same viewcontroller many times

Hi! I learned about transitions with viewcontrollers with the iOS Animations_by_tutorials book, now I want to presenting a viewcontroller many times, the only that change is the data, it is like that the netflix app do http://www.yourfilelink.com/get.php?fid=2092972, I know how make the transition, but that I don’t know how call the same viewcontroller itself, without it crashing y show the error : " Application tried to present modally an active controller"

Thanks

Hi @armi,
You will have to instantiate the viewController manually and pass it the data.

The error that you are describing is because you may be trying to present the same instance instead of a new one.

You can instantiate a new one using the storyboardAPI function called instantiateViewController(withIdentifier: "YOUR_VC_NAME")
and then present this viewcontroller modally.

cheers,

This topic was automatically closed after 166 days. New replies are no longer allowed.