Auto Generate Reports

Hi all,

I’m developing a software with some reports.

I’m exporting my data as .dbf files and I want to use libreoffice to generate the reports.
I’ve create a odb file linked to the folder where I export the data and I’ve created some reports.
If I open the odb file and I click in the reports it generate the report properly, but I need to do this automatically (from my application just launch the report).

What is the best way to archive that?

PS:
I created a macro to run the report and I’m trying to call is through command line but it doesn’t work.
Command: “soffice “pathToFile\LineMap.odb” “macro://LineMap/Standard.Reports.OpenMyReport””

Many thanks.

If executing "libreoffic6.2 --help | grep "{macro" I get:

user@system:> libreoffice6.2 --help | grep "{macro"
   {file} {macro:///Library.Module.MacroName}

and this shows three slashes /// after “macro:” while your command above just shows two of 'em. Just a hint, may mean nothing but may be the cause of your command not working.

Finally I don’t understand LineMap/ in your path to the macro, since from help I cannot see any / allowed in the specification of which macro to execute. Thus I’d expect something like:

soffice "pathToFile\LineMap.odb" "macro:///Standard.Reports.OpenMyReport"
(if you haven’t defined your own library and therefore your macro resides in “Standard”)

@anon73440385 thanks. I’ve managed to make it work.