The only thing I can find so far is this which just opens the dialog box, it does not change any settings for me.
Code: Select all
dispatcher.executeDispatch(document, ".uno:PageFormatDialog", "", 0, Array())
Any help would be great.
Code: Select all
dispatcher.executeDispatch(document, ".uno:PageFormatDialog", "", 0, Array())
Code: Select all
view= thiscomponent.getCurrentController()
fam=thiscomponent.stylefamilies.getbyname("PageStyles")
sh=view.getActivesheet()
style=fam.getbyname(sh.PageStyle)
Code: Select all
Dim pageOptions(0) As New com.sun.star.beans.PropertyValue
pageOptions(0).Name = "ScaleToPagesX"
pageOptions(0).Value = 1
thisComponent.Printer = pageOptions()
Code: Select all
view= thiscomponent.getCurrentController()
fam=thiscomponent.stylefamilies.getbyname("PageStyles")
sh=view.getActivesheet()
style=fam.getbyname(sh.PageStyle)
style.ScaleToPagesX = 1