I’m using the combobox control from the Ajax toolkit. Is there a way to set the image thats used for the button that shows up next to the dropdown box or am I stuck with the standard one?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
I’ve never used this control, however I looked at the Ajax Control Toolkit demo site to take a look at it. It looks like the arrow button is simply a button (as zakster82 mentioned). On the ComboBox control itself, set the CssClass and then define the button descendant for that class with a different background image. Something like this:
Same padding / margins might be required to clean this up, obviously.
On a side note, I’d recommend not using the Ajax Control Toolkit as, like zakster82, I’ve found that a number of the controls on there are not quite production quality. Also many of them (the ComboBox included) are little more than fancy JavaScript that isn’t even all that fancy and can muck up your markup. Obviously this is just my opinion. Your mileage may vary.