We need you!

We're working hard on the next version of Developer Fusion. Let us know what you think we should be up to!

Members

Technology Zones

Articles

Hosted By

MaximumASP

Info

Rated
Read 23,107 times

Related Categories

Changing the look of command button - Changing the look of command button

Abdul

Changing the look of command button

This code will change the font of the command button to bold when the mouse moves over it and it will become default when the mouse moves out. You can change anything for command button or any other GUI control.  
---------------------------------
Put a commandbutton on the center of the form and put this code in:

Private Sub Command1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Command1.FontBold = True

End Sub

Private Sub Form_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Command1.FontBold = False
End Sub

Comments

  • image in button

    Posted by lkwl on 25 Feb 2004

    :( At the first glance of the title, I thought I found what I looking for. No... VB has such a boring command button. And I was trying to add an image to it and set the left/right alignment. No way I ...

  • try this

    Posted by Santosh_Shitole on 22 Dec 2003

    try this

    create a array of the command button
    Option Explicit

    Private Sub Command1_Click(Index As Integer)
    Select Case Index
    Case 0
    MsgBox "Button1"
    Case 1
    ...

  • HELP!

    Posted by Dainesy_Daisey on 12 Dec 2003

    I am a total noob 2 visual basic......so i was wonderin is there a way 2 get this piece of code 2 affect every single command button in a project??? :confused: