Skip to content

Instantly share code, notes, and snippets.

@kgbu
Created May 21, 2010 18:43
Show Gist options
  • Select an option

  • Save kgbu/409246 to your computer and use it in GitHub Desktop.

Select an option

Save kgbu/409246 to your computer and use it in GitHub Desktop.
Sub chkpagenator()
'
' chkpagenator Macro
' 見出し1でもないのに、段落前で改ページしている要素を発見する
'
Dim p As Paragraph
Dim s As Style
For Each p In ActiveDocument.Paragraphs
Set s = p.Style
If Not s.NameLocal Like "*見出し*" Then
If p.PageBreakBefore < 0 Then
MsgBox (p.Range & s.NameLocal & ":" & p.OutlineLevel & ":" & p.PageBreakBefore)
End If
End If
Next p
End Sub
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment