|
Private Sub Workbook_BeforePrint(Cancel As Boolean)
Dim nm, i&
nm = Array("Sheet2", "Sheet3")
For i = 0 To UBound(nm)
Sheets(nm(i)).PageSetup.LeftFooter = "&""宋体""&10" & "设计负责人:" & Sheets("Sheet1").Range("D7").Value
Sheets(nm(i)).PageSetup.CenterFooter = "&""宋体""&10" & "审核:" & Sheets("Sheet1").Range("D9").Value & " 编制:" & Sheets("Sheet1").Range("D8").Value
Sheets(nm(i)).PageSetup.RightFooter = "&""宋体""&10" & "编制日期:" & Sheets("Sheet1").Range("D10").Value
Next
End Sub
以上宏可以在2003版本工作簿ThisWorkbook中运行,为什么到2010版本就不行了呢?麻烦高手看看,谢谢!
|
|