Macro aus der Konsole aufrufen

Registriert
Jan. 2010
Beiträge
2.020
Hi @All,

Wie kann man ein makro welches im Libreoffice funktioniert von einer Konsole ausführen? Problem dabei ist das das Makro nicht ausgeführt wird im Konsolenmodus mit dem Befehl:
Code:
soffice --headless "macro:///Standard.Module1"
Es kommt jedoch auch keine Fehlermeldung. Das Makro verschiebt Tabelle einer Datei um diese als csv exportieren zu können.
 
Ich komme nochmal auf deinen Thread von vor ein paar Tagen zurück. Habe selber nochmal einen Blick in den Link von mir geworfen, hast du die letzte Antwort davon gesehen? Dein Vorhaben scheint ja doch ohne Macro zu gehen: https://wiki.documentfoundation.org/ReleaseNotes/7.2#Document_Conversion

The --convert-to csv:... command line spreadsheet conversion or export filter options string accepts a new optional 12th numeric parameter, which makes it possible to export the entire document to individual sheets .csv files or a specified sheet. tdf#135762 (Caolán McNamara, Red Hat; Eike Rathke, Red Hat)
For example:
soffice --convert-to csv:"Text - txt - csv (StarCalc)":44,34,UTF8,1,,0,false,true,false,false,false,-1 sample.ods
  • 0 or absent means the default behaviour, first sheet from command line, or current sheet in macro filter options, exported to sample.csv
  • -1 for all sheets, each sheet is exported to an individual file of the base file name concatenated with the sheet name, for example sample-Sheet1.csv, sample-Sheet2.csv and sample-Sheet3.csv
 
  • Gefällt mir
Reaktionen: ModellbahnerTT
Zurück
Oben