4 ms·
Python on LibreOffice appears to be more concerned with moving GUI elements and not enough with manipulating cells. There doesn't appear to be a straightforward
by varunnrao 2y ago
Python on LibreOffice appears to be more concerned with moving GUI elements and not enough with manipulating cells. There doesn't appear to be a straightforward library/module which helps me access specific cells and get their values. This would be a greater value proposition than allowing me to control Calc as a puppet using a Python script which seems to be their main idea.
- buovjaga 2y agoDid you try the ScriptForge library shipped with LibreOffice: https://help.libreoffice.org/latest/en-US/text/sbasic/shared/03/sf_toc.html https://help.libreoffice.org/latest/en-US/text/sbasic/shared... See the SFDocuments.Calc service there. ScriptForge makes it more convenient to work with the API. Using it with Python: https://help.libreoffice.org/latest/en-US/text/sbasic/shared/03/sf_intro.html https://help.libreoffice.org/latest/en-US/text/sbasic/shared...
- varunnrao 2y agoI hadn't come across the ScriptForge library before so I just looked it up. It looks pretty cool and definitely looks like how MSFT should have worked on including Python in Excel. From my quick look, it looks like ScriptForge is primarily a BASIC which supports Python(?). So I can only imagine how much more powerful a Python specific library could be given the differences in Python and BASIC themselves.
- buovjaga 2y agoNo need to use BASIC, you can use ScriptForge in LibreOffice Python macros directly. ScriptForge is also available for use with LibreOffice BASIC macros.