Closed rockstarvibu closed 4 years ago
reply
DragSelectGridView
cannot provide you such information because it doesn't link any data to any index. In fact, the indexes are used by the library users to decide which widget to build in DragSelectGridView.itemBuilder
, not by the library itself.
As this issue doesn't concern the library, I'm closing it. However, I believe I should be able to help you with your problem if you give me more details about what are you trying to do. Some code would also help :)
Hey i just want to get the selected values in array... For eg... User selected 5 items out of 100 items and when he clicks on FAB button then on next screen 5 selected values should come instead of 5 index in array. Can u help me with this?
Thanks
?
I'm guessing you have access to the list with your values, so you could do something like:
final selectedValues = controller.value.selectedIndexes.map((index) => myValues[index]);
If this doesn't help you, I'll need some minimal piece of reproducible code to get a better understanding of your situation.
Hey I'm able to get Selected index by calling controller.value. but instead of indexes I want the values which the user selected.. how to do that... Thanks