Hi John, my last problem I can't solve... I need to recreate this tool, but I only have the .ppam file
I need to split one text box of bullets so each bullet is in it's own text box. I've attached a PowerPoint slide visually explaining a bit better.
It's used because often we split a text box of bullets into one bullet per box, and then we can paste data from Think-Cell using the PPTX clipboard (a feature Think-Cell has, an add-in for PowerPoint).
My code so far, but it bolds/centers and changes bullets
Any help is appreciated, thank you.
PS: Made a small donation, enjoy some wine I'm so grateful for your help.
Code:
Sub SplitBullets8()
Dim oShp As Shape
Dim oTB As Shape
Dim oSld As Slide
Dim L As Long
Dim sngT As Single
Dim sngW As Single
Dim sngL As Single
Dim otxR1 As TextRange
Dim FM As Single
Dim LM As Single
Dim fontsz As Long
'On Error GoTo err
Set oShp = ActiveWindow.Selection.ShapeRange(1)
sngL = oShp.Left
sngW = oShp.Width
Set oSld = oShp.Parent
fontsz = oShp.TextFrame.TextRange.Paragraphs(1).Font.Size
Set otxR1 = oShp.TextFrame.TextRange.Paragraphs(1)
LM = oShp.TextFrame.Ruler.Levels(1).LeftMargin
FM = oShp.TextFrame.Ruler.Levels(1).FirstMargin
For L = 1 To oShp.TextFrame.TextRange.Paragraphs.Count
If L = 1 Then
sngT = oShp.Top
Else
sngT = otxR1.BoundTop + otxR1.BoundHeight
End If
Set oTB = oSld.Shapes.AddTextbox(msoTextOrientationHorizontal, sngL, sngT, sngW, 10)
oTB.TextFrame.TextRange.Text = oShp.TextFrame2.TextRange.Paragraphs(L).Text
Set otxR1 = oTB.TextFrame.TextRange
While Right(otxR1.Text, 1) = Chr(13)
otxR1.Text = Left(otxR1.Text, Len(otxR1.Text) - 1)
Wend
otxR1.ParagraphFormat.Bullet.Visible = _
oShp.TextFrame2.TextRange.Paragraphs(L).ParagraphFormat.Bullet.Visible
otxR1.ParagraphFormat.Bullet.Type = _
oShp.TextFrame.TextRange.Paragraphs(L).ParagraphFormat.Bullet.Type
oTB.TextFrame.TextRange.Font.Size = fontsz
oTB.TextFrame.Ruler.Levels(1).FirstMargin = FM
oTB.TextFrame.Ruler.Levels(1).LeftMargin = LM
Next L
oShp.TextFrame.DeleteText
oShp.Delete
Exit Sub
err:
MsgBox "Error, " & err.Description
End Sub