Skip to Content
avatar image
Former Member

Enabling all Check Box using single Button in SAP UI5.

Hello All,

I am trying to enable All the CheckBox on my screen using single button click. But i am not able to do that i have tried many things but it is not working. Please help me.


<mvc:View controllerName="CheckBox.controller.check1" xmlns:html="" xmlns:mvc="sap.ui.core.mvc"
	displayBlock="true" xmlns="sap.m">
			<Page title="{i18n>title}">
						<Button text="Select All" press="onPress"/>
						<CheckBox text="Option a" id="cb"/>
						<CheckBox text="Option b" name="cb"/>
						<CheckBox text="Option c" name="cb"/>
						<CheckBox text="Option d" name="cb"/>
						<CheckBox text="Option e" name="cb"/>
						<CheckBox text="Warning" valueState="Warning" name="cb" />
						<CheckBox text="Error" valueState="Error" name="cb"/>


], function(Controller) {
	"use strict";

	return Controller.extend("CheckBox.controller.check1", {
		onPress: function() {
		sap.m.MessageBox.alert("Hii all");
			//alert("Hi all");


Even Alert message is also not getting dispalyed.

Please help me solve this.

Thanks & regards,

Urvish Panchal

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    Mar 29, 2017 at 11:50 AM
    Add comment
    10|10000 characters needed characters exceeded