I was wondering how could I do this. I know I can use the button component but it has the little gray stuff around it when I give it a image. With image button how could I show another image for the hover effect
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.
You want to create a button with no border but displays different images when the user hovers over it with the mouse? Here’s how you can do it:
Add an
ImageListcontrol to your form at add two images, one for the button’s normal appearance and one for when the mouse is hovering over.Add your button and set the following properties:
FlatStyle= FlatFlatAppearance.BorderColor(and maybeMouseOverBackColor&MouseDownBackColor) to your form’s background colorImageList= the ImageList you added to the formImageIndexto the index value of your normal imageCode the MouseHover and MouseLeave events for the button like this:
I believe that will give you the visual effect you’re looking for.