Hai, How to add icon or image on right side of the raddropdowlist ? I am dynamically added dropdowlist via code and i need to add icon on right side of the control (inside the control) ,In textbox i can add, like this i want to add icon, here i attach screenshot.
Hai, any reply on this i want to show icon on right side of the dropdown list for
1. If dropdown list is empty 2,if dropdown list have value like "Yes" and "No", if user selected "No", then need to show icon in right side with that value (NO)
1 Answer, 1 is accepted
0
Dess | Tech Support Engineer, Principal
Telerik team
answered on 01 Aug 2023, 08:53 AM
Hello, Aravind,
I have prepared a sample code snippet for your reference which result is illustrated in the below screenshot:
Hi, Thanks for reply , 1 .Icon need to add when ddl is empty also, i mean ddl got items, but not select any item, that time need to show error icon like validation .Below the screenshot what i want
2. Need to show icon on right side of text when select "No" , and not in the list added, below the screenshot what i want
3. Icon not showed when i select item programmatically, i mean i added icon in the list , but when select item "No" via code, icon not appear, below the screenshot
when i click dropdown list then only icon appear.
I want to show icon when select the "No" via code.
Thank you for the additional screenshots and details.
1. If you need to show an icon when no item is selected, it is appropriate to handle the SelectedIndexChanged event and set the DropDownListElement.EditableElement.Image:
3. If the RadListDataItem is added with specified Image property, once this item is selected (no matter if programmatically or by the UI), the respective image is expected to be shown. Please refer to the attached sample project that I have prepared for your reference.
Please give it a try and see how it works on your end.
1. If dropdown list is empty
2,if dropdown list have value like "Yes" and "No", if user selected "No", then need to show icon in right side with that value (NO)