Thread: Font Object
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Stefi Stefi is offline
external usenet poster
 
Posts: 2,646
Default Font Object

Try this piece of code for copying format of cell A1 to B1:

Range("A1").Copy
Range("B1").PasteSpecial Paste:=xlPasteFormats, Operation:=xlNone, _
SkipBlanks:=False, Transpose:=False
Application.CutCopyMode = False

Regards,
Stefi


€˛Jack Clift€¯ ezt Ć*rta:

How do I set the font property of a cell / range to be the same as a
reference cell, without going through all the myriad of font properties and
setting individually

I have tried all manner of variations on the theme:

dim oFont as Font

set oFont = RefRange.Font
TargetCell.Font = oFont

Does not work and all manner of mucking around has not improved results

Thanks

Jack