Makro Druckbereich

Programmierung unter AOO/LO (StarBasic, Python, Java, ...)

Moderator: Moderatoren

F3K Total
********
Beiträge: 3724
Registriert: Mo, 28.02.2011 17:49

Re: Makro Druckbereich

Beitrag von F3K Total »

Hi,
versuche es mal hiermit:

Code: Alles auswählen

sub S_print_Tabelle1
    dim printProp() as new com.sun.star.beans.PropertyValue
    ocontroller = thiscomponent.currentcontroller
    ocurrentsheet = ocontroller.activesheet
    osheet = Thiscomponent.sheets.getbyname("Tabelle1")
    ocontroller.activesheet = osheet
    thiscomponent.print(printProp)
    wait 1000
    ocontroller.activesheet = ocurrentsheet
end Sub

sub S_print_Tabelle2
    dim printProp() as new com.sun.star.beans.PropertyValue
    ocontroller = thiscomponent.currentcontroller
    ocurrentsheet = ocontroller.activesheet
    osheet = Thiscomponent.sheets.getbyname("Tabelle2")
    ocontroller.activesheet = osheet
    thiscomponent.print(printProp)
    wait 1000
    ocontroller.activesheet = ocurrentsheet
end Sub
Gruß R