//========================
以下巨集是在OpenOffice下執行可透過巨集控制直接,
將文件頁面由「直向」轉換為「橫向」。
//========================
sub nym1
Dim Doc As Object
Dim DateTimeField As Object
Dim PageStyles As Object
Dim StdPage As Object
Dim FooterCursor As Object
Dim PageNumber As Object
Doc = StarDesktop.CurrentComponent
PageNumber = Doc.createInstance("com.sun.star.text.textfield.PageNumber")
PageNumber.NumberingType = com.sun.star.style.NumberingType.ARABIC
PageStyles = Doc.StyleFamilies.getByName("PageStyles")
StdPage = PageStyles("Default")
StdPage.IsLandscape = True
StdPage.Width = 29700
StdPage.Height = 21000
end sub
沒有留言:
張貼留言