I want to enter the same data into multiple cells that are not adjacent. I have selected the cells and pressed CTRL + ENTER but this doesn't work.
AFAIK, you can't do this for non-adjacent cells in OpenOffice or LibreOffice Calc (this is different from Excel - there, you can use CTRL+Enter on non-contiguous ranges). For adjacent cells, use ALT+ENTER to enter data or formula into all selected cells. Works both in OpenOffice Calc and LibreOffice Calc.
From the LibreOffice Calc Help (https://help.libreoffice.org/Calc/Shortcut_Keys_for_Spreadsheets):
To fill a selected cell range with the formula that you entered on the Input line, press Alt+Enter.
There does not seem to be any way to select multiple nonadjacent cells and then type in a value to fill all cells. Using Alt+Enter gives the following message.
Insert into multiple selection not possible.
Instead, in LibreOffice, first enter the value into a single cell, then copy (Ctrl+c or the menu). After that, select multiple nonadjacent cells and paste (Ctrl+v or the menu).
Paste multiple does not work in Apache OpenOffice. However a macro could be written and assigned to a hotkey. Here is some code to get started.
Sub DisplaySelectedRanges oSels = ThisComponent.CurrentSelection For selIndex = 0 to oSels.getCount() - 1 oSel = oSels.getByIndex(selIndex) Print(oSel.AbsoluteName) Next selIndex End Sub