# How to get the index value of selected checkbox in checkboxlist

**URL:** <https://forum.radzen.com/t/how-to-get-the-index-value-of-selected-checkbox-in-checkboxlist/12723>\
**Category:** Angular\
**Created:** [January 8, 2023, 11:37pm UTC](https://forum.radzen.com/t/how-to-get-the-index-value-of-selected-checkbox-in-checkboxlist/12723 "2023-01-08T23:37:26Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![AbhishekJ](https://forum.radzen.com/letter_avatar_proxy/v4/letter/a/a9adbd/32.png) [@AbhishekJ](https://forum.radzen.com/u/AbhishekJ)\
**Post date:** [January 8, 2023, 11:37pm UTC](https://forum.radzen.com/t/how-to-get-the-index-value-of-selected-checkbox-in-checkboxlist/12723/1 "2023-01-08T23:37:26Z")

</div>

Hello,

 ![doubt](https://forum.radzen.com/uploads/default/original/2X/9/908a3e611758503ad94048ac7904426c34b6c48e.jpeg)

Out of the above given options. If I select 'A' , I am trying to get the index value of 0 which is the index in an array format. Similarly for 'B' it should return 1 and for 'C' it should return 2. but upon using ${event.indexOf(checkboxlist0.Selected)} the only value I am getting is -1. Is there anyway to solve this?

---

<div class="post-metadata">

**Author:** ![enchev](https://forum.radzen.com/user_avatar/forum.radzen.com/enchev/32/16_2.png) [@enchev](https://forum.radzen.com/u/enchev)\
**Post date:** [January 9, 2023, 5:05am UTC](https://forum.radzen.com/t/how-to-get-the-index-value-of-selected-checkbox-in-checkboxlist/12723/2 "2023-01-09T05:05:54Z")

</div>

If your options are populated from a variable like in this [thread](http://forum.radzen.com/t/dynamic-one-to-many-checkbox-list/1092) you should check this variable using the event argument for the index.
