From a design point of view, I would create a service.
The service should have a STRING input and output.
In the Composer, when building the Mashup you can then map the text input as input parameter for the service.
The label will then be mapped to the output of the service.
The button should trigger service invokation.
The service itself can then use the input and run through if cases or switches and deliver an output result that matches your expectations.
With this, when you enter something in the text box and click the button the service is called, return a result that's then showing up as a text for the label.
Hi Dipika Sengupta,
Another alternative way could be to add an Application Parameter and write Angular JS functions for each button to update the Application Parameter according to the condition.
So, on click of button; the Application Parameter will be updated which in-turn is linked to the message/label widget.
I hope it helps.