批量调整word表格根据窗口调整内容
生活随笔
收集整理的這篇文章主要介紹了
批量调整word表格根据窗口调整内容
小編覺得挺不錯的,現(xiàn)在分享給大家,幫大家做個參考.
Sub CenterTable() Application.Browser.Target = wdBrowseTable
For i = 1 To ActiveDocument.Tables.Count
ActiveDocument.Tables(i).AutoFitBehavior (wdAutoFitWindow) '根據(jù)窗口調(diào)整內(nèi)容 ActiveDocument.Tables(i).Range.ParagraphFormat.Alignment = wdAlignParagraphCenter '水平居中 ActiveDocument.Tables(i).Range.ParagraphFormat.Alignment = wdCellAlignVerticalCenter '垂直居中 Next i End Sub
For i = 1 To ActiveDocument.Tables.Count
ActiveDocument.Tables(i).AutoFitBehavior (wdAutoFitWindow) '根據(jù)窗口調(diào)整內(nèi)容 ActiveDocument.Tables(i).Range.ParagraphFormat.Alignment = wdAlignParagraphCenter '水平居中 ActiveDocument.Tables(i).Range.ParagraphFormat.Alignment = wdCellAlignVerticalCenter '垂直居中 Next i End Sub
轉(zhuǎn)載于:https://blog.51cto.com/2197042/1059476
總結
以上是生活随笔為你收集整理的批量调整word表格根据窗口调整内容的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 位图排序(计数排序)
- 下一篇: 优秀员工与普通员工