Question change the border color of a label after running the program

pooya1072

Well-known member
Joined
Jul 5, 2012
Messages
84
Programming Experience
Beginner
Hi friends
There is two control in my form,a label and a button , i want when i click the button ,the color of label's border change.
Thanks
 
Assuming that you've set BorderStyle property of the Label, you can't easily change the colour of that border, as far as I'm aware. I'd suggest that the easiest option is to put the Label on a Panel and make the Panel the appropriate number of pixels bigger in each direction. The overhanging Panel will then create a border around the Label and you can change it's colour by setting the BackColor property of the Panel.
 
Back
Top