Update a label through button from different view

后端 未结 2 1267
离开以前
离开以前 2020-12-07 04:56

How to update a label by button clicks when they both are in different classes of uiview controller...when button is clicked,the label should be update...i tried many times.

2条回答
  •  长情又很酷
    2020-12-07 05:21

    Not sure if it's a good solution, but you could store the text in a global NSString when clicking on the button, then put that string into your label when loading the second view.

提交回复
热议问题