I have requirement to use two combo box (multi select dropdown). When first combo box select multiple items then as per this items i need to set records in second combo box.
I am following below url for combo box
https://www.infragistics.com/products/ignite-ui-angular/angular/components/combo.html
I am not found any function or event to clear combo box and set value in combo box
can you please help me?
@nikunjgajera ,
You can use the combo method deselectAllItems() to clear the selection.
To set the selection, you can use selectAllItems(), by passing an array of the objects you want to select from your data. You can specify whether the previously selected items should be cleared by passing the second parameter, clearSelection.
The IgxComboalso supports value binding via [(ngModel)] - you can use that for the cascading scenario and also for clearing the selected values (by setting the bound property to [])
Here is the StackBlitz example which illustrates the above concepts.
@ViktorSlavov thanks i will try it
@ViktorSlavov its working perfectly
thanks once again
Most helpful comment
@nikunjgajera ,
You can use the combo method deselectAllItems() to clear the selection.
To set the selection, you can use selectAllItems(), by passing an array of the objects you want to select from your data. You can specify whether the previously selected items should be cleared by passing the second parameter,
clearSelection.The IgxComboalso supports value binding via
[(ngModel)]- you can use that for the cascading scenario and also for clearing the selected values (by setting the bound property to[])Here is the StackBlitz example which illustrates the above concepts.