Hi,
Is it possible to have an embedded font?
Is there maybe a macro that will install a font when
you open the sheet, and uninstall it when you exit for example?
Please help me out!
Thanks, Tom
Hi,
Is it possible to have an embedded font?
Is there maybe a macro that will install a font when
you open the sheet, and uninstall it when you exit for example?
Please help me out!
Thanks, Tom
Yes. Macro1 selects a cell ( in this case A1) and applies formats to it:
Sub Macro1()
Range("A1").Select
Selection.NumberFormat = "$#,##0.00"
With Selection
.HorizontalAlignment = xlCenter
.VerticalAlignment = xlCenter
.WrapText = False
.Orientation = 0
.AddIndent = False
.IndentLevel = 0
.ShrinkToFit = False
.ReadingOrder = xlContext
.MergeCells = False
End With
With Selection.Font
.Name = "Courier New"
.FontStyle = "Bold"
.Size = 8
.Strikethrough = False
.Superscript = False
.Subscript = False
.OutlineFont = False
.Shadow = False
.Underline = xlUnderlineStyleNone
.ColorIndex = xlAutomatic
End With
Selection.Borders(xlDiagonalDown).LineStyle = xlNone
Selection.Borders(xlDiagonalUp).LineStyle = xlNone
With Selection.Borders(xlEdgeLeft)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
With Selection.Borders(xlEdgeTop)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
With Selection.Borders(xlEdgeBottom)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
With Selection.Borders(xlEdgeRight)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
With Selection.Interior
.ColorIndex = 36
.Pattern = xlSolid
.PatternColorIndex = xlAutomatic
End With
End Sub
Macro2 clears all format on the active worksheet:
Sub Macro2()
Cells.Select
Selection.ClearFormats
End Sub
and could be run prior to saving the workbook.
--
Gary's Student
"tomkorver" wrote:
>
> Hi,
> Is it possible to have an embedded font?
> Is there maybe a macro that will install a font when
> you open the sheet, and uninstall it when you exit for example?
> Please help me out!
> Thanks, Tom
>
>
> --
> tomkorver
> ------------------------------------------------------------------------
> tomkorver's Profile: http://www.excelforum.com/member.php...o&userid=34619
> View this thread: http://www.excelforum.com/showthread...hreadid=543951
>
>
You can't embed a font in excel.
I've never seen any one post a macro that would do what you want.
A search of Google through the *VB* newsgroups gets lots of hits.
Here's one:
http://groups.google.co.uk/group/mic...d935ca6e55ba42
or
http://snipurl.com/qpsu
And another shorter version:
http://groups.google.co.uk/group/mic...2e251e2c8461bb
or
http://snipurl.com/qpt0
Maybe you can make one of them work.
tomkorver wrote:
>
> Hi,
> Is it possible to have an embedded font?
> Is there maybe a macro that will install a font when
> you open the sheet, and uninstall it when you exit for example?
> Please help me out!
> Thanks, Tom
>
> --
> tomkorver
> ------------------------------------------------------------------------
> tomkorver's Profile: http://www.excelforum.com/member.php...o&userid=34619
> View this thread: http://www.excelforum.com/showthread...hreadid=543951
--
Dave Peterson
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks