We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on : November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

deselect item / clear

Thread ID:

Created:

Updated:

Platform:

Replies:

131569 Jul 17,2017 10:35 AM UTC Jul 19,2017 12:36 PM UTC JavaScript 3
loading
Tags: ejDropDownList
Luis Carlos
Asked On July 17, 2017 10:35 AM UTC

Hi.

in the next image you can see the "ejDropdownlist" component with two options and the first is selected. How can I deselected the first option? I mean, I would like to change the value "Si" to null or ''. Could be possible?



I will be awating four your reply, thanks in advance.

Kind regards, Luis.

Keerthana Rajendran [Syncfusion]
Replied On July 18, 2017 05:30 AM UTC

Hi Luis,   
   
Thank you for contacting Syncfusion Support.   
   
Yes, we can deselect an item using clearText method of DropDownList. We have prepared a sample to deselect an item on button click. Please refer to the given link   
   
   
If you want to unselect a particular item, we can use any one of the below methods   
   
   
Regards,   
Keerthana.  
 


Luis Carlos
Replied On July 18, 2017 06:41 AM UTC

Hi again.

I use the "ejDropdownlist" component into "ejGrid" component, so I can't use a button to clear select. I would like to know if there is another solution, for instance, a blue X as you can see in the next picture.


I will be awating for your reply, thanks again.


Kind regards, Luis.


Keerthana Rajendran [Syncfusion]
Replied On July 19, 2017 12:36 PM UTC

Hi Luis, 
 
We have modified a sample based on your requirement. Please refer to the below given link 
 
 
We have added the close icon to input element during select event of DropDownList and click event has been bound to it. We have used clearText method inside this click event so text will be cleared on clicking the icon as per your requirement. 
 
Regards, 
Keerthana.   
 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;