event dropdownlist element id

hello 
 How do I get the dropdownlist id I clicked on?
Because I can not see it on the list


example : cart_drpProductMainGroup id 

thank you
function drpselectchange(sender) {
     
     $("#" + this.id).css("border", "")
}

  $('#cart_drpProductMainGroup').ejDropDownList({
            dataSource: units,
            fields: { id: "id", text: "text" },
            width: 260,
            showCheckbox: false,
            dataSource: GetMainGroups(),
            fields: { id: "GroupID", text: "Name" },
            select: "drpselectchange",
            create: "drpcreate",
            popupHide: "drppopuphide",
            popupShown: "drppopupshow",
            beforePopupShown: "drpbeforepopupshow",
            change: "drpvaluechange",
            select: "drpselectchange",
            actionComplete: "drpactionComplete",
            actionFailure: "drpactionFailure",
            actionSuccess: "drpactionSuccess",

            enableFilterSearch: true,
            enablePopupResize: true,
        });
 

1 Reply

KR Keerthana Rajendran Syncfusion Team August 7, 2017 09:42 AM UTC

Hi Serdar,   
   
Thank you for contacting Syncfusion Support.   
   
We suggest to use “this._id” instead of this.id in your code to get the id of current DropDownList. Please refer the given code   
   
function drpselectchange(sender) {   
            $("#" + this._id+"_container").css("border", "1px solid black")   
        }   
  
   
We have attached a sample for your reference. Please refer to the below link   
   
      
Regards,   
Keerthana 


Loader.
Up arrow icon