打印 MS Word 网格线?

打印 MS Word 网格线?

Word 具有非常方便的网格线功能,可让您查看任意大小的网格线,并将文档中的元素与网格线对齐。您可以在“布局”选项卡>“对齐”>“查看网格线”中启用此功能。

然而,打印时这些网格线并不存在,但启用打印功能的选项似乎是一个显而易见的功能。

我找遍了所有地方,还是没找到办法。网上有很多解决方案声称可行,但根本行不通。这篇 MS 支持文章提供了一个解决方案(其中有一个错误 - “页面设置”位于“布局”选项卡下,而不是“设计”选项卡下)。但它在第二步就失败了,因为“页面设置”对话框中不存在“打印设置”选项卡。

这个超级用户问题也没有令人满意的答案。第一个回复链接了一篇文章,其中提供了截取页面截图作为解决方案,这看起来非常过时,而且质量很差。第二个回复建议绕过 grindlines 功能本身,只需在 Word 文档上粘贴一个看起来像网格的背景,但缺少所有出色的功能和设置。

我尝试在 Google 和 YouTube 上寻找解决方案,但一无所获。有人知道怎么做吗?考虑到 MS Word,打印网格线似乎是一个非常简单且明显的功能已经有了网格线。

答案1

Word 没有此功能。这些网格线不用于打印。

这些网格线旨在帮助您在页面上放置打印项目。但最终产品中不会显示这些网格线。

您可以创建并使用方格纸模板

你可以从我的网站下载一些模板。下面的截图来自四分之一英寸模板。

截屏

以下是链接Word MVP Bill Coan 的宏创建这些。我修改过的宏版本的打印输出包含在我的网站和下面的下载包中。下载中没有活动的宏。

这里是我修改后的宏版本:

Sub GraphPaperCreate()
'   TechTrax - Bill Coan
'   http://web.archive.org/web/20070421084938/http://pubs.logicalexpressions.com/Pub0009/LPMArticle.asp?ID=596
'   modified by Charles Kenyon to:
'       reduce margins to .25
'       lighter line weight (.3 points rather than 2 points)
'       grid is set behind text in case there is text
'
' Sets margins at .25"  Charles Kenyon
'
    With ActiveDocument.PageSetup
        .TopMargin = InchesToPoints(0.25)
        .BottomMargin = InchesToPoints(0.25)
        .LeftMargin = InchesToPoints(0.25)
        .RightMargin = InchesToPoints(0.25)
    End With

    'Declare variables
    Dim sglBeginX As Single
    Dim sglEndX As Single
    Dim sglBeginY As Single
    Dim sglEndY As Single
    Dim Interval As Single
    Dim LineCount As Integer
    Dim VerticalGridLines As Integer
    Dim HorizontalGridLines As Integer
    Dim GridWidth As Single
    Dim GridHeight As Single
    Dim UserChoice As String
    Dim oLine As Shape

    'set the line weight, in points
    Const LINE_WEIGHT As Long = 0.5   'changed from Integer = 2 by Charles Kenyon - this is the minimum

    'set whether to delete the old grid,
    '(assuming there is one)
    Const DELETE_OLD_GRID As Boolean = True

    'Delete the old grid
    If DELETE_OLD_GRID Then
       On Error Resume Next
       ActiveDocument.range.ShapeRange.Delete
       On Error GoTo 0
    End If

    'Prompt the user to specify the size of squares desired
PromptUser:
    UserChoice = InputBox _
    ("Enter size of squares in points:" & vbLf & vbLf & _
       "(Value must be between 1 and 72)" & vbLf & _
       "9 points = 1/8 inch" & vbLf & _
       "12 points = 1/6 inch" & vbLf & _
       "18 points = 1/4 inch" & vbLf & _
       "24 points = 1/3 inch" & vbLf & _
       "36 points = 1/2 inch" & vbLf & _
       "48 points = 2/3 inch" & vbLf & _
       "72 points = one inch", "Create graph paper")

    'If the size requested is outside the allowed range,
    'then go back and prompt the user again,
    'but if user has clicked cancel, then quit
    If IsNumeric(UserChoice) Then
       Interval = Val(UserChoice)
       If Interval > 72 Or Interval < 2 Then
          MsgBox "Value must be between 2 and 72.", _
            vbOKOnly + vbInformation, "Value out of range"
          GoTo PromptUser
       End If
    ElseIf UserChoice = "" Then
       GoTo EndGracefully
    Else
       GoTo PromptUser
    End If

    'Calculate beginning and ending positions
    'based on page size and margins
    With ActiveDocument.Sections.First.PageSetup
       sglBeginX = .LeftMargin
       sglEndX = .PageWidth - .RightMargin
       sglBeginY = .TopMargin
       sglEndY = .PageHeight - .BottomMargin
    End With

    'Calculate how many squares of the requested size
    'can fit in the available area
    HorizontalGridLines = Int((sglEndY - sglBeginY) / Interval)
    VerticalGridLines = Int((sglEndX - sglBeginX) / Interval)

    'Calculate the size of the finished grid, based on
    'size of the number of lines and the size of the squares
    GridWidth = VerticalGridLines * Interval
    GridHeight = HorizontalGridLines * Interval

    'draw the horizontal lines
    For LineCount = 0 To HorizontalGridLines
       Set oLine = ActiveDocument.Shapes.AddLine( _
          BeginX:=sglBeginX, _
          BeginY:=sglBeginY + LineCount * Interval, _
          EndX:=sglBeginX + GridWidth, _
          EndY:=sglBeginY + LineCount * Interval)
       oLine.line.Weight = LINE_WEIGHT
       oLine.ZOrder msoSendBehindText   'Charles Kenyon
    Next LineCount

    'draw the vertical lines
    For LineCount = 0 To VerticalGridLines
       Set oLine = ActiveDocument.Shapes.AddLine( _
          BeginX:=sglBeginX + LineCount * Interval, _
          BeginY:=sglBeginY, _
          EndX:=sglBeginX + LineCount * Interval, _
          EndY:=sglBeginY + GridHeight)
       oLine.line.Weight = LINE_WEIGHT
       oLine.ZOrder msoSendBehindText   'Charles Kenyon
    Next LineCount

    'release the oLine object from memory
    Set oLine = Nothing

    'end gracefully
EndGracefully:

End Sub

生成的网格可以放置在页眉或页脚中作为普通文本的背景。

相关内容