Skip to Content
0

Select list item programmatically is not working

Jul 13, 2017 at 12:48 PM

54

avatar image
Former Member

Hi ,

I want to select first item in my master list. I used the below code for that.

list = this.getView().byId("myList");

list.setSelectedItem(list.getItems()[0], true /*selected*/, true /*fire event*/);

But it's not working. Any one faced this issue? Please help

Thanks

Saranya

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

2 Answers

avatar image
Former Member
Jul 13, 2017 at 11:14 PM
0

HI

I do not think that it is a good idea to do things that way that you have.

Can you please consider this? http://jsbin.com/mebeziv/edit?js,output

Thanks

-D

Share
10 |10000 characters needed characters left characters exceeded
avatar image
Former Member Jul 14, 2017 at 12:43 PM
0

Dear,

First check whether list is loaded. You' can use uploadcompleted event, with in you can perform above activi

Share
10 |10000 characters needed characters left characters exceeded