Create a segue to another view controller on a watch app but prevent the Cancel/Back option in the top title bar?

Wondering if there's a way to have a segue from one view controller to another (for a watch app) but prevent the user from being able to see or click on a 'back' or 'cancel' button on the top title bar of the view controller. (I don't want the user to be able to jump back to the starting page.)


Similar to how the Apple Workout app seems to work..A user selects a workout from the list, the specific Workout comes up and starts, but the user can not hit 'back' or 'cancel' on the title bar when the workout starts..(they would have to swipe right and end the workout session)


(newbie to swift/xcode but haven't been able to find anything to prevent this 'back' option on title bar)


Thanks in advance for any information, direction, help!

I don't think you can disable the Cancel. You can rename, but not disable.


Look here on using reloadRootPageControllers(withNames:contexts:orientation:pageIndex:):

https://stackoverflow.com/questions/30642573/how-to-disable-cancel-button-interaction

thanks for the response Claude31...I ran across that article also at some point in my search. It just seems so weird that i can't disable this 'feature' to prevent a user from stepping back a screen. (i even tried to rename the title to " "...which leaves it blank..but a user can still touch the top title bar to get it to go back.)


will try seeing if reloadRootControllersWithNames works.


Also just found this on SO thats a bit more recent:

https://stackoverflow.com/questions/49310723/remove-top-left-back-button

Yes the mechanisms of "segue" in WatchOS are a bit surprising compared to iOS.


I tried also to blank the title, but no effect.

Create a segue to another view controller on a watch app but prevent the Cancel/Back option in the top title bar?
 
 
Q