Draw a Double Line in Word 2007?

R

Ryan

I've pulled my hair out many times trying to use this pos Office 2007. One
of the annoyances was trying to draw a double line.

I draw a line, right-click, select Format Autoshape, then try to change the
Style to a double-line, but it's greyed out.

Any ideas?

And if you'll allow me to rant a little bit, I just want to use Word... this
new interface is tedious and time consuming. I don't want to fart around
with a ribbon, just give me a menu bar.


Ryan
 
G

Greg Maxey

Ryan,

For whatever reason the developers of Word2007 did not see a need for fancy
line segments. You are right that option is not available for line segments
drawn with Word2007. I believe this issue has been reported to MS. Who
knows, it may be restored with Word2010.

All is not lost if you still have access to Word 2003 (or even a Word 2003
document containing a line segment). Line segments created in a Word2003
document and cut/pasted to a Word2007 document can still be modified using
the Style window (weird yes).

If you use lines often, you could save a Word2003 line as a QuickPart.
Insert it where you want and then format it like you did in Word2003.

I can send you a Word2003 document containing a line segment if you need it.




I've pulled my hair out many times trying to use this pos Office
2007. One of the annoyances was trying to draw a double line.

I draw a line, right-click, select Format Autoshape, then try to
change the Style to a double-line, but it's greyed out.

Any ideas?

And if you'll allow me to rant a little bit, I just want to use
Word... this new interface is tedious and time consuming. I don't
want to fart around with a ribbon, just give me a menu bar.


Ryan

--
Greg Maxey

See my web site http://gregmaxey.mvps.org
for an eclectic collection of Word Tips.

"It is not the critic who counts, not the man who points out how the
strong man stumbles, or where the doer of deeds could have done them
better. The credit belongs to the man in the arena, whose face is
marred by dust and sweat and blood, who strives valiantly...who knows
the great enthusiasms, the great devotions, who spends himself in a
worthy cause, who at the best knows in the end the triumph of high
achievement, and who at the worst, if he fails, at least fails while
daring greatly, so that his place shall never be with those cold and
timid souls who have never known neither victory nor defeat." - TR
 
S

Suzanne S. Barnhill

Unfortunately, the Line Style option for drawing lines was removed from Word
2007.

--
Suzanne S. Barnhill
Microsoft MVP (Word)
Words into Type
Fairhope, Alabama USA
http://word.mvps.org
 
G

Greg Maxey

Ms. Barnhill,

Actually the option is disabled for line segments drawn with Word2007. The
option is still available and enabled for line segments drawn with Word2003.
Unfortunately, the Line Style option for drawing lines was removed
from Word 2007.

--
Greg Maxey

See my web site http://gregmaxey.mvps.org
for an eclectic collection of Word Tips.

"It is not the critic who counts, not the man who points out how the
strong man stumbles, or where the doer of deeds could have done them
better. The credit belongs to the man in the arena, whose face is
marred by dust and sweat and blood, who strives valiantly...who knows
the great enthusiasms, the great devotions, who spends himself in a
worthy cause, who at the best knows in the end the triumph of high
achievement, and who at the worst, if he fails, at least fails while
daring greatly, so that his place shall never be with those cold and
timid souls who have never known neither victory nor defeat." - TR
 
S

Suzanne S. Barnhill

Oh, that's good news, at least for those of us still running Word 2003 and
2007 side by side.

--
Suzanne S. Barnhill
Microsoft MVP (Word)
Words into Type
Fairhope, Alabama USA
http://word.mvps.org
 
G

Greg Maxey

Take a look at my reply to Ryan. If you use fancy line segments you can put
together a crude work around as long as you have access to a Word2003
document containing a line segment.

Oh, that's good news, at least for those of us still running Word
2003 and 2007 side by side.

--
Greg Maxey

See my web site http://gregmaxey.mvps.org
for an eclectic collection of Word Tips.

"It is not the critic who counts, not the man who points out how the
strong man stumbles, or where the doer of deeds could have done them
better. The credit belongs to the man in the arena, whose face is
marred by dust and sweat and blood, who strives valiantly...who knows
the great enthusiasms, the great devotions, who spends himself in a
worthy cause, who at the best knows in the end the triumph of high
achievement, and who at the worst, if he fails, at least fails while
daring greatly, so that his place shall never be with those cold and
timid souls who have never known neither victory nor defeat." - TR
 
L

Lene Fredborg

I found out that even if the four double/tripple line styles known from
previous Word versions are not available in the user interface in Word 2007,
you have access to the line styles via VBA – and this means that you can use
a macro to apply a double/tripple line style. As Greg said, once you have
such line in a Word 2007 document, you can change the line style of that line
to one of the other double/tripple line styles via the Format AutoShape
dialog box.

The macro below creates a 5 cm long horizontal line and applies the “two
thin lines†line style (the remaining line styles are listed below the
macro). For further details, see the comments in the macro.

--------------------
Sub AddLineShape_DoubleLineStyle()

Dim oShape As Shape
Dim nStartHor As Single
Dim nStartVer As Single

'Find the point where the top and left margins intersect
'Use this point as the starting point for the line
nStartHor = ActiveDocument.PageSetup.LeftMargin
nStartVer = ActiveDocument.PageSetup.TopMargin

With ActiveDocument
'Create a vertical line, length 5 cm
Set oShape = .Shapes.AddLine(nStartHor, nStartVer, nStartHor +
CentimetersToPoints(5), nStartVer)
With oShape
.Line.Style = msoLineThinThin
.Line.Weight = 3
End With
End With

'Clean up
Set oShape = Nothing
End Sub

--------------------
To apply one of the other double (or tripple) line styles, replace the code
lines:

.Line.Style = msoLineThinThin
.Line.Weight = 3

with the appropriate set of lines below:


.Line.Style = msoLineThinThick
.Line.Weight = 4.5

or

.Line.Style = msoLineThickThin
.Line.Weight = 4.5

or

.Line.Style = msoLineThickBetweenThin
.Line.Weight = 4.5

--
Regards
Lene Fredborg - Microsoft MVP (Word)
DocTools - Denmark
www.thedoctools.com
Document automation - add-ins, macros and templates for Microsoft Word
 
R

Ryan

Thank you for the prompt, though unsatisfying response.

I was able to use the workaround you suggested.
 
R

Ryan

Assuming the ability to create buttons tied to a macro hasn't been taken
away, I might just do this. Thank you.
 
L

Lene Fredborg

You can assign the macro to a button in the Quick Access Toolbar (QAT) via
Office button > Word Options > Customize. If you select “Macros†in the
top-left list, you can find the desired macro in the list below from where
you can add it to the QAT list to the right. Make sure to select the
appropriate document or template in the top-right list.

--
Regards
Lene Fredborg - Microsoft MVP (Word)
DocTools - Denmark
www.thedoctools.com
Document automation - add-ins, macros and templates for Microsoft Word
 
G

Greg Maxey

I found out that even if the four double/tripple line styles known from
previous Word versions are not available in the user interface in Word 2007,
you have access to the line styles via VBA – and this means that you can use
a macro to apply a double/tripple line style. As Greg said, once you have
such line in a Word 2007 document, you can change the line style of that line
to one of the other double/tripple line styles via the Format AutoShape
dialog box.

The macro below creates a 5 cm long horizontal line and applies the “two
thin lines” line style (the remaining line styles are listed below the
macro). For further details, see the comments in the macro.

--------------------
Sub AddLineShape_DoubleLineStyle()

    Dim oShape As Shape
    Dim nStartHor As Single
    Dim nStartVer As Single

    'Find the point where the top and left margins intersect
    'Use this point as the starting point for the line
    nStartHor = ActiveDocument.PageSetup.LeftMargin
    nStartVer = ActiveDocument.PageSetup.TopMargin

    With ActiveDocument
        'Create a vertical line, length 5 cm
        Set oShape = .Shapes.AddLine(nStartHor, nStartVer, nStartHor +
CentimetersToPoints(5), nStartVer)
        With oShape
            .Line.Style = msoLineThinThin
            .Line.Weight = 3
        End With
    End With

    'Clean up
    Set oShape = Nothing
End Sub

--------------------
To apply one of the other double (or tripple) line styles, replace the code
lines:

            .Line.Style = msoLineThinThin
            .Line.Weight = 3

with the appropriate set of lines below:

            .Line.Style = msoLineThinThick
            .Line.Weight = 4.5

or

            .Line.Style = msoLineThickThin
            .Line.Weight = 4.5

or

            .Line.Style = msoLineThickBetweenThin
            .Line.Weight = 4.5

--
Regards
Lene Fredborg - Microsoft MVP (Word)
DocTools - Denmarkwww.thedoctools.com
Document automation - add-ins, macros and templates for Microsoft Word







- Show quoted text -

Lene,

Nice sluething ;-) Since the line built with VBA is fully formattable
(i.e., style is enabled). I would do it like this and then edit the
line segment by selecting it and formatting autoshape:

Sub BuildFullyFormatableLine()
Dim oShp As Word.Shape
Dim i As Long
Dim j As Long
i = Selection.Information(wdVerticalPositionRelativeToPage)
j = Selection.Information(wdHorizontalPositionRelativeToPage)
'Add a one inch long horizontal line segment at the selection.
Set oShp = ActiveDocument.Shapes.AddLine(i, j, i + 72, j)
With oShp.Line
.Style = msoLineSingle
.Weight = 0.75
End With
Set oShp = Nothing
End Sub
 

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