error-heading.jpgHi John
Just testing lovely buttons you helped with, and I have one weird outcome on a heading that's underlined (code I adapted ).
With the *.pptm file open it works fine on its ribbon
When the *.ppam is installed, the tool fails, re image attached.
My code is:
Sub RedHeading()
Set B = ActiveWindow.View.Slide.Shapes.AddTextbox(msoTextOrientationHorizontal, 45.5, 98.9, 725, 400)
With B.TextFrame2
.MarginTop = 0
.MarginBottom = 0
.MarginLeft = 0
.MarginRight = 0
.VerticalAnchor = msoAnchorBottom
With .TextRange
.Text = "Heading Text"
With .Font
.Name = "Arial"
.Size = "12"
.Bold = True
.Fill.ForeColor.RGB = RGB(219, 0, 17)
End With
End With
Set myDocument = ActivePresentation.Slides(1)
With myDocument.Shapes.AddLine(45.5, 127, 770, 127).Line
.ForeColor.RGB = RGB(219, 0, 17)
.Weight = 1
End With
End With
End Sub
Function cm2Points(inVal As Single)
cm2Points = inVal * 28.346
End Function
Thank you in advance