Quantcast
Channel: VBForums - Visual Basic .NET
Viewing all articles
Browse latest Browse all 27554

VS 2010 change event when mouse is clicked outside a panel

$
0
0
Hi i am trying to work out the event that handles when i click outside a area "i guess that is how to put it"

This is exactly what i mean

I have a panel i.e
Code:

ProfileNamePanel
and a text box i.e

Code:

Profile_NameTextBox
I whish for the ProfileNamePanel to change color when i click inside the Profile_NameTextBox which i obviously done using

Code:


    Private Sub Profile_NameTextBox_MouseClick(ByVal sender As System.Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles Profile_NameTextBox.MouseClick


        ProfileNamePanel.BackColor = Color.Aquamarine

    End Sub

BUT now i am stuck trying to work out what event handles changing the color again say to black once i have clicked away from

Profile_NameTextBox


So in short i whish to change a panels color when i click on a textbox then after i finish that textbox and click elsewhere i want to change the color of the panel again.

Cheers in advance

Viewing all articles
Browse latest Browse all 27554

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>