VBcoders Guest



Don't have an account yet? Register
 


Forgot Password?



Command Button Change Forecolor (Trick)

by Kevin (5 Submissions)
Category: Coding Standards
Compatability: Visual Basic 5.0
Difficulty: Beginner
Date Added: Wed 3rd February 2021
Rating: (10 Votes)

Ever wanted to give your boring Command Buttons a different text color? Here's your chance ;)

Rate Command Button Change Forecolor (Trick)


 
 
  
 

  Change the forecolor of a 
  "Command Button"...

 
 
  1) 
  Add a check-box on your form and rename it to "Command1"

  2) Set it style-property to "1 - Graphical"

  3) Add the following code to "Command1_MouseUp"...
 
 
  
  
 
 
  
  Command1.Value = 0
 
 
  
  
 
 
  Of 
  course you could also use the hard-way, But I'd prefer this way.

  A check-box supports the same events anyway...


  I hope you liked this small trick.

  Kevin,
 
 

Download this snippet    Add to My Saved Code

Command Button Change Forecolor (Trick) Comments

No comments have been posted about Command Button Change Forecolor (Trick). Why not be the first to post a comment about Command Button Change Forecolor (Trick).

Post your comment

Subject:
Message:
0/1000 characters