Setting Cell Font with VBA


February 08, 2002 - by Juan Pablo Gonzalez

Meredith asks:

I am writing a macro that will assign a check to the active cell i have chosen. My code is as follows:

ActiveCell.FormulaR1C1 = "x" 

I want to know how to change the font from Arial to Wingdings in my macro. Can you help me figure out the code to format my active cell with a specific font and assign my "*" symbol???

Thank you for your help.



Ranges have a Font object, that handle all the things that you can do with it, that is, make it bold, change its size and change the font, among others. All you have to do is:

ActiveCell.Font.Name = "Wingdings"