我想删除文档中的页码,只有在附录部分中。有没有办法用IF语句修改下面的代码来检查Section是否是附录样式然后执行?
Sub DeletePageNumbers()
Dim objSect As Section
Dim objHF As HeaderFooter
Dim objPNum As PageNumber
For Each objSect In ActiveDocument.Sections
For Each objHF In objSect.Headers
For Each objPNum In objHF.PageNumbers
objPNum.Delete
Next
Next
For Each objHF In objSect.Footers
For Each objPNum In objHF.PageNumbers
objPNum.Delete
Next
Next
Next
End Sub
答案 0 :(得分:0)
我明白了。见下面的代码
set terminal gif
set xtics rotate
plot "test.csv" u 0:3:xtic(1) t "Avg" with lines, \
"test.csv" u 0:4:5:6:7 t "MinMax&Stdv" with candlesticks