Skip to Content
0
Former Member
Mar 04, 2009 at 09:37 AM

How to change the button text at runtime.

1015 Views

Hi experts,

In my dialog program I have a button in the main screen which, when clicked for the first time, will show a subscreen in the main screen, and when clicked for the second time, will make the subscreen to disappear. This is working fine but my requirement is that, I want to toggle the button text as well with the clicks - i.e., when the user clicks for the first time, the subscreen should appear and the text of the button should change to DISPLAY THE SCREEN. On clicking for the second time the screen should disappear and the button text should change to "HIDE THE SCREEN." Can anyone please give me some hints of how to change the button text at runtime? Thanks in advance.