Hi Mauritio,
I can adapt my code using your example with no problems to create the spreadsheet but I need one more step .
I wish that when the user opens with libreoffice calc an xml file launches my python script to get the spreadsheet back.
How I can teach libreoffice calc to load the spreadsheet using my script ?
This solution is close to what makes ms excel that does its best to show the xml file as a spreadsheet.
My code is generic enough to handle many xml files without problems , then I would teach libreoffice to open xml files using calc and do not write how it happens.
Where can I find the documentation that explains how to do it ?
Thank you very much.
[Added after response to add details]
the use case that I would handle is the following:
- Mary wants to open an XML file with libreoffice but She want to see it as a spreadsheet in cal.
- She selects the xml file and using the right mouse button and she choose the option " open with libreoffice calc "
- calc forwards the xml file to my python script that loads the spreadsheet
- once the spreadsheet is populated with the values coming from the xml file She can save it in csv or xls or ods file.
I hope I explained it better.