Edit this page

select

Select a Button.

Parameters

li jQuery | Number

LI element or index of the Button.

Example

<div data-role="view" data-init="setSelected">
  <ul id="buttongroup" data-role="buttongroup">
    <li>Option 1</li>
    <li>Option 2</li>
    <li>Option 3</li>
  </ul>
</div>

<script>
var app = new kendo.mobile.Application();

function setSelected() {
  var buttongroup = $("#buttongroup").data("kendoMobileButtonGroup");

  // selects by jQuery object
  buttongroup.select(buttongroup.element.children().eq(0));
  // selects by index
  buttongroup.select(1);
}
</script>
Is this article helpful? Yes / No
Thank you for your feedback!

Give article feedback

Tell us how we can improve this article

close
Dummy