Hello,
I am trying to map the text in an Excel cell to a textbox in a webpage, but Power Automate writes all the text consecutively and ignores new lines. To solve this, I tried to split the text by using the "new line" delimiter but the issue still remains. The "Populate text field in webpage" action is a non-option because it deletes the entry of the previous index when making the entry for the current index.
Also, the "send keys" action does not write the first letter of the first word.
How can I map the text exactly as shown in the Excel cell?
Ah, apologies, I forgot to mention the most important part!
In your Populate text field on web page, untick "Populate text using physical keystrokes"
Try deactivating escape sequences in Replace text. Also, are you still doing this with Send keys?
-------------------------------------------------------------------------
If I have answered your question, please mark it as the preferred solution. If you like my response, please give it a Thumbs Up.
I also provide paid consultancy and development services using Power Automate. If you're interested, DM me and we can discuss it.
The break points are found with \n, but the Replace with: \n<BR> part does not create a new line. Instead it outputs the text "<BR>" between the break points. \r produces the same result as well.
\r?\n successfully detects the new lines, but the problem is with the Replace text: {Enter} part. The actual text '{Enter}' is outputted in the breakpoints rather than the key {Enter}. Is there a way I can send an enter key inside the Replace text action?
I've come across this before, do me a favour, in a vacuum setting, just set up a "Launch a browser instance" (whichever you use) and have it attach to the window in which you want to write your text into, now just use a "Populate text field on webpage" with emulated typing and write this into the box:
Some issues were spotted in the ticket:
<BR>
<BR>
Some Note
(<BR> is an HTML tag for a Single Line Break, i.e. new line)
See if that creates two new lines for you, if it does, proceed with the following:
Instead of splitting your text, just use a Replace text,
In your Replace text, create it as in the image below, replace %NewVar% with the variable containing all the text from the cell:
(If it does not work first time try \r as suggested if it is indeed carriage returns)
Try experimenting with different expressions you may need. For instance, try simply using \r (which stands for a carriage return) instead of \r?\n. If Replace text doesn't find the exact pattern, it will simply not replace anything, but will keep the original value in %Replaced%. So, if your value does not actually have newlines (to be replaced by \n) but only has carriage returns, using \r?\n will not replace anything, but \r could.
-------------------------------------------------------------------------
If I have answered your question, please mark it as the preferred solution. If you like my response, please give it a Thumbs Up.
I also provide paid consultancy and development services using Power Automate. If you're interested, DM me and we can discuss it.
The Replace text action produces the same result as the Split text action. The text is still mapped into one line and new lines are ignored. Here is an image of the actions I am using. Is there something I am missing?
Okay. Why are you using the clipboard there? You don't need to set the clipboard text and then get it. You already have the value in a variable.
Also, I don't see any Replace text actions there. As suggested, if you want to use Send keys (which is recommended, because Populate text field in web page does in fact ignore newlines), you should use Replace text to replace \r?\n (using regex) with {Enter} so that the Enter key is sent by Send keys to create a new line.
-------------------------------------------------------------------------
If I have answered your question, please mark it as the preferred solution. If you like my response, please give it a Thumbs Up.
I also provide paid consultancy and development services using Power Automate. If you're interested, DM me and we can discuss it.
The values are pulled from the appropriate cells. The issue is that the text in the Excel cell has new lines (circled in image 1 of 2), and the text that Power Automate maps ignores new lines (circled in image 2 of 2).
Michael E. Gernaey
497
Super User 2025 Season 2
David_MA
436
Super User 2025 Season 2
Riyaz_riz11
244
Super User 2025 Season 2