I have two buttons on my mainScreen. When a button is tapped, I set a global variable for the button's value. (just a string, e.g. Button1). After the button selection, a detailScreen is opened. I want to set a label on the detailScreen. to use the string that was set on the mainScreen.
Code to call the detail screen from the button.TouchUpInside is in the MainScreen ViewDidLoad(). And I set the label in the detailScreen, in the ViewDidLoad in the DetailScreen. But it only gets called once, when I tap on the Back Button and selected another button, the label does not change.
Is there another event I should use? A short snippet would be appreciated.