# Removing macros [closed]

I have a couple of spreadsheets that are distant versions (via "save as..." many times over) of a spreadsheet originally created in MS Excel. When I open the LibreOffice versions, I get a macro warning. Since the spreadsheets don't use macros, I'd like to get rid of the warning. When I go in to Organize Macros, I can see some structure in there but no actual macros to delete, and the delete key is grayed out as well. How can I get rid of all this?

edit retag reopen merge delete

### Closed for the following reason the question is answered, right answer was accepted by Alex Kemp close date 2015-10-26 22:17:27.928637

I would have liked to try your solution of saving the spreadsheet as a .fods (plain text) file, but I can't see how to do this in the save as dialog other than as a .cvs file - this is the olny save as text option in there in my version of Calc (LibreOffice 3.5.7.2 Build ID: 350m1(Build:2)).

( 2013-03-14 09:45:10 +0100 )edit

The save option is called OpenDocument Spreadsheet (Flat XML) (.fods). It appears 5th on the list of Save as Type options in my LO 3.5.4.2 and LO 4.0.1.2 (and even in OpenOffice 3.2, but further down on the list).

( 2013-03-14 14:56:21 +0100 )edit

Sort by » oldest newest most voted

While playing around with this, I have been able to achieve my desired result by going into Tools|Macros|Organize Dialogs and selecting the libraries tab, then choosing the filename from the location drop down and deleting the library in there (the standard library remains and can't be deleted). After saving and re-opening the spreadsheet, the macro warning no longer appears.

more

This worked well for me. It is a little bit harder to find now, more like: Tools|Macros|Organize|Libreoffice Basic|Organizer but it seems to have removed the warning.

One detail I would add: if the file is to be saved back to "xls" format you may need to open it and resave it once in LO first otherwise some Excel versions may look for the non existant macro "file" and crash. After I re-saved it this no longer happened.

( 2018-10-26 13:35:08 +0100 )edit

I don't know of an easy way to get rid of that irksome Macro warning, but try this (on a copy of your file). Save the spreadsheet as a .fods file (plain text). Open the file with a text editor and locate the section starting with <office:scripts>. Delete the code

<ooo:library-embedded ooo:name="Standard">
[several lines of xml and basic code]
</ooo:library-embedded>


and re-save the file.

more

STELLAR!!! this solved MY problem too!!! should be made permanent part of the ref guide!!!

( 2013-06-29 23:47:12 +0100 )edit

I finally got around to trying this method - works great! The spreadsheet was too big for Kate to open (more than 65000 lines!) but it was no problem with vi. There were four or five embedded libraries in there.

( 2014-09-09 16:34:48 +0100 )edit

thanks man, didn't know about "flat" formats until now :-)

( 2016-11-29 21:37:18 +0100 )edit

Worked for me in Writer too - saved it as a FODT, then edited it with notepad (using the FIND function to assist!).

Interesting though that the "FLAT" file is 150k when original ODT was 39k???

( 2016-12-19 10:05:50 +0100 )edit

Doesn't "FLAT" mean "Uncompressed"?

( 2018-11-01 09:40:41 +0100 )edit