Level of skill: None - searching as I go to try and figure it out.
I currently have a Google sheet in which I am trying to automatically convert all numbers (1,2,3...) to roman numerals (I,II,III, etc).
I do have a very lengthy work around after having tested with recording small macros and pasting them all together. See example below: spreadsheet.getRangeList(['E1:E2']).setFormula('=IFERROR(ROMAN(D1;0);"")');
This sets the roman value next to the cell with the number. Google sheets does auto update when shifting down for cells so that works..
Which I then have it cut and paste the value of in the original cell.
Rinse repeat for every range on the sheet that contains numbers.
This feels extremely clunky to me and must be a better way. Either by removing the cut/paste section and store the value as part of the function, or simply check each in the sheet, if a number, apply function, if not, move on... or any other method that would work well.
For clarification, there are empty spots/areas where there is no data.
Example:
A | B | C | D | E | F | G | H | I |
---|---|---|---|---|---|---|---|---|
1 | Apple | 3 | Potato | 5 | ||||
2 | Pear | 1 | ||||||
3 | Celery | 0 | ||||||
4 | Carrot | 2 | Tomato | 4 |
Desired Output
A | B | C | D | E | F | G | H | I |
---|---|---|---|---|---|---|---|---|
1 | Apple | III | Potato | V | ||||
2 | Pear | I | ||||||
3 | Celery | 0 | ||||||
4 | Carrot | II | Tomato | IV |
Any guidance/ideas would be much appreciated. Even if it is just a link to what functions/info to go read up on as I don't mind the journey and learning.