[JS] modification d'une selection
Hi there,
I am looking to modify paragraphs, one after the other in a selection. But each time the paragraph line is replaced, the carriage return is taken with it and it is deleted if I add a «\r», I still have my two paragraphs but the following one takes on its style (it's logical) How to replace the content of the paragraph without taking the last character (the «\r»).
Here is the order and some illustrations thank you
Bonjour à tous,
Je cherche à modifié des paragraphes l'un après l'autre dans une selection.
Mais à chaque remplacement de la ligne de paragrphe le retour chariot est pris avec et le suprime si je rajoute un «\r», j'ai toujours mes deux pargraphe mais le suivent prend son style (c'est logique)
Comment arrivé à remplacer le contenu du paragraphe sans prendre le dernière caractaire (le «\r»).
voici la commande et des illustrations
app.selection[0].paragraphs[1].contents = '— test —';
le resulta


