Text box line indent problems in PP 2003

P

pasdetrois

I am using a PP template provided by my customer. It has multitudes of
text boxes on the page, and many but not all have the 2nd line indent
set. I want everything left-justified. I know to use the ruler tab to
move the indent over to the left, but it appears I have to do this for
each occurrence of the problem (each text box). Since I have thousands
of these text boxes in the documents, this is not efficient.

Is there a way to left justify everything in a couple steps, or am I
stuck with adjusting each one?

Thanks.
 
G

Guest

Go to View > Master > SLide Master and make the indent adjustments there.
Hopefully your client used the master to set up text boxes. If not, each
will have to be adjusted separately.
 
P

pasdetrois

Unfortunately the text boxes are not in the Master. I think she just
dropped them in on the page. But I appreciate your help.
 
G

Guest

Maybe you could use a vba macro??

It might look like this (use a copy as there are no guarantees!)

Sub leftalign()

Dim oSld As Slide
Dim oShp As Shape

For Each oSld In ActivePresentation.Slides
For Each oShp In oSld.Shapes
If oShp.HasTextFrame Then
oShp.TextFrame.Ruler.Levels(1).LeftMargin = 0
End If

Next oShp
Next oSld
End Sub
--
 
D

David M. Marcovitz

This code seems to work well. Depending on exactly what is indented, you
might also want to set the FirstMargin to 0:

Sub leftalign()
Dim oSld As Slide
Dim oShp As Shape

For Each oSld In ActivePresentation.Slides
For Each oShp In oSld.Shapes
If oShp.HasTextFrame Then
oShp.TextFrame.Ruler.Levels(1).FirstMargin = 0
oShp.TextFrame.Ruler.Levels(1).LeftMargin = 0
End If

Next oShp
Next oSld

End Sub

Additionally, be warned that this will change all text boxes, so if there
are titles or other miscellaneous text boxes that you don't want changed,
this will mess with those as well.

--David

Maybe you could use a vba macro??

It might look like this (use a copy as there are no guarantees!)

Sub leftalign()

Dim oSld As Slide
Dim oShp As Shape

For Each oSld In ActivePresentation.Slides
For Each oShp In oSld.Shapes
If oShp.HasTextFrame Then
oShp.TextFrame.Ruler.Levels(1).LeftMargin = 0
End If

Next oShp
Next oSld
End Sub



--
David M. Marcovitz
Microsoft PowerPoint MVP
Director of Graduate Programs in Educational Technology
Loyola College in Maryland
Author of _Powerful PowerPoint for Educators_
http://www.PowerfulPowerPoint.com/
 
S

Steve Rindsberg

I am using a PP template provided by my customer. It has multitudes of
text boxes on the page, and many but not all have the 2nd line indent
set. I want everything left-justified. I know to use the ruler tab to
move the indent over to the left, but it appears I have to do this for
each occurrence of the problem (each text box). Since I have thousands
of these text boxes in the documents, this is not efficient.

Is there a way to left justify everything in a couple steps, or am I
stuck with adjusting each one?

Excellent question ... and here's the result:

Working with Tab settings in text
http://www.rdpslides.com/pptfaq/FAQ00794.htm
 
G

Guest

Steve

Useful code but not sure that tab stops are the problem here and your
code(Get) crashed on me, I think it only works if there are inserted tab
stops. (It worked great when there were) --

_____________________________
John Wilson
Microsoft Certified Office Specialist
 
G

Guest

Titles should be OK as they do not usually have hanging indents. The code
does mess up bullets placeholders, so here is version 2

Sub leftalign()

Dim oSld As Slide
Dim oShp As Shape

For Each oSld In ActivePresentation.Slides
For Each oShp In oSld.Shapes
If oShp.HasTextFrame Then
If oShp.TextFrame.TextRange.ParagraphFormat.Bullet.Visible = False Then
With oShp.TextFrame.Ruler.Levels(1)
..FirstMargin = 0
..LeftMargin = 0
End With
End If
End If

Next oShp
Next oSld
End Sub
--
-----------------------------------------
Did that help?
_____________________________
John Wilson
Microsoft Certified Office Specialist
 
S

Steve Rindsberg

John Wilson said:
Steve

Useful code but not sure that tab stops are the problem here

On re-read, I think you're right. "2nd line indent" and all.
and your
code(Get) crashed on me, I think it only works if there are inserted tab
stops. (It worked great when there were) --

Well ... the insrux *did* say to choose a text box that has the tabs you want
to duplicate set already. <g>

But good catch. I've surrounded it with an If .TabStops.Count > 0 / End If
block in the updated version.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top