Visual Basic Font Property

Brett964
Brett964 used Ask the Experts™
on
Hi, I need to know how to dynamically change the font property of a command button. The default font is "MS Sanf" and I would lie to change it to "Arial"

Thanks!
Brett
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Commented:
if your commandbutton is called cmd and is in Form1,


Form1.cmd.Font = "Arial"

sometimes you might even need to call

Form1.cmd.refresh

Could it get easier?

Commented:
Sometimes VB is wonderful

Author

Commented:
Thank you so much! I suppose I was trying to make it A LOT harder than it was!

Thanks!

Commented:
You are welcome.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial