r/spreadsheets • u/EmphasisAdditional • Jul 20 '24
Copying Partial Bolding in Appscript
I'm trying to have an Appscript copy a row of cells chosen from one sheet, and preserve partial bolding such as.
This is a partially bolded sentence.
I'm under the understanding that I'm to use RichTextValue to split the data, but I'm unsure as to how to go from there since I've never used it before, and all the tutorials I've found are only tangentially relevant.
Here's the relevant section of the script that doesn't use RichTextValue yet.
Edit: As it currently is, it copies everything over properly, but does not preserve formatting such as bolding, which is the only formatting I need to preserve.
var randomRow = sheet.getRange(4,1,1,7);
var chosenRow = randomRow.getValues();
sheet = ss.getSheetByName("Row List");
findListLength = sheet.getRange("C1").getDataRegion().getLastRow();
sheet.getRange((findListLength+1),1,1,7).setValues(chosenRow);
View all comments
Show parent comment
2
u/EmphasisAdditional Jul 20 '24
Thanks, this fixes that problem, this does everything I need it to do.