cancel
Showing results for 
Search instead for 
Did you mean: 

how to deselect item in List

Former Member
0 Kudos
1,486

Hi All,

  I am using List (Object List Item) to display data. i want to deselect items which are selected when i click on one button (3Selected).

can anybody help me on this.

Thanks & Regards,

Siddappa.

Accepted Solutions (0)

Answers (5)

Answers (5)

0 Kudos

If you accidentally select an item from a list and need to remove it, hold down the CTRL button (on a Windows PC) or the Command button and click on the item you want to uncheck. This will deselect the item and it will no longer be highlighted.

This may help you,

Rachel Gomez

0 Kudos

What about the Opa test api for deselected the rows? I found one on Wiki iDeselectAlllistItems(), but after run the test cases, shows up error said this is not a function, no matter I use Given, When or Then.

former_member204155
Active Participant
0 Kudos

Hi,

You can use setSelected(false) function of super class sap.m.ListItemBase

regards

Kuntal

Private_Member_15166
Active Contributor
0 Kudos

On press event of button, write this.

press: function(){

var itemId = sap.ui,getCore().byId("ListId");               // ListId is ID of your objectList

itemId.removeSelections(true);

}

Qualiture
Active Contributor
0 Kudos

Have you looked at the API yet? There is a method that does exactly that

former_member182372
Active Contributor
0 Kudos

API documentation? Never heard of such.....

Qualiture
Active Contributor
0 Kudos

Apparently you're not the only one