Change a button image/picture box image when mouse enter

Dear EE,

I want to created my own buttons for my applications,
and I want it when I mouseEnter in a image, it will change to another image...
How can I do that?

I tried this but it fails :(

 Private Sub picBtnFTP_MouseEnter(ByVal sender As Object, ByVal e As System.EventArgs) Handles picBtnFTP.MouseEnter

        Dim pPath As String
        pPath = AppPath() & "\1.jpg"
        Me.picBtnFTP.Image.FromFile(pPath)


    End Sub


How can I change that?
If possible easier than I can just change the opacity instead of another image, can save more resources...
Thanks you
joely2kAsked:
Who is Participating?
 
Mike TomlinsonMiddle School Assistant TeacherCommented:
Something like this will work:

    Private Sub picBtnFTP_MouseEnter(ByVal sender As Object, ByVal e As System.EventArgs) Handles picBtnFTP.MouseEnter

        Dim pPath As String
        pPath = Application.StartupPath & "\1.jpg"
        picBtnFTP.Image = Image.FromFile(pPath)

    End Sub

~IM
0
 
joely2kAuthor Commented:
Thanks Idle Mind for your help.....
Appreciated..
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.