How to detect de-selection of an opton

Hello Team

i am trying to show and hide some controls based on selection and deselection of multiselect dropdown component 

On (select) event multiselect is working and its hiding the required content - but on *de-selection* - 

what event should we use to show them back

https://stackblitz.com/edit/angular-pzfdz8?file=app.component.html


Thanks

Mohit



3 Replies

PM Ponmani Murugaiyan Syncfusion Team January 14, 2022 05:57 AM UTC

Hi Mohit, 

Greetings from Syncfusion support. 

Query: But on *de-selection* - what event should we use to show them back. 
 
You can use the removed event to detect the deselection item in the popup. 

<ejs-multiselect 
        id="multiselect-checkbox" #checkbox [dataSource]="myc" [placeholder]="checkWaterMark" [fields]="mycheckFields" 
        [mode]="mode" [popupHeight]="popHeight" [showDropDownIcon]="true" [filterBarPlaceholder]="filterPlaceholder" 
        (select)="testSelect($event)" (removed)="testUnSelected($event)" 
      ></ejs-multiselect> 

testUnSelected(args) { 
    //triggers on DeSelection 
  } 

 
Regards, 
Ponmani M 



RM Raj Maheshwari January 14, 2022 11:27 AM UTC

Thank you for quick response - this will do for us.

Mohit



PM Ponmani Murugaiyan Syncfusion Team January 17, 2022 04:29 AM UTC

Hi Mohit, 

Thanks for the update. Please get back us if you need further assistance. 

Regards, 
Ponmani M 


Loader.
Up arrow icon