# How to detect a Line Break inside a character array from string (or inside a string)?

**URL:** <https://forums.unrealengine.com/t/how-to-detect-a-line-break-inside-a-character-array-from-string-or-inside-a-string/616913>\
**Category:** Programming & Scripting\
**Tags:** unreal-engine\
**Created:** [July 29, 2022, 5:42am UTC](https://forums.unrealengine.com/t/how-to-detect-a-line-break-inside-a-character-array-from-string-or-inside-a-string/616913 "2022-07-29T05:42:33Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Onoa](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Onoa](https://forums.unrealengine.com/u/Onoa)\
**Post date:** [July 29, 2022, 5:42am UTC](https://forums.unrealengine.com/t/how-to-detect-a-line-break-inside-a-character-array-from-string-or-inside-a-string/616913/1 "2022-07-29T05:42:33Z")

</div>

Hi,

Does anyone know how to detect a Line Break symbol inside a character array from string?

Basically, I want to replace all the characters inside a string, but keep the Line Return characters at their exact positions inside the string.

Using the following BP logic, I can detect any character, but not the Line Break one. I’m using the SHIFT-ENTER character to test the Line Break inside the string.

Thank you.

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/4/a/1/4a1b4002a55ebb1e668a8cd87471b39e8c168a50.png)

---

<div class="post-metadata">

**Author:** ![AnthonyDerossi00](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@AnthonyDerossi00](https://forums.unrealengine.com/u/AnthonyDerossi00)\
**Post date:** [September 23, 2022, 3:41pm UTC](https://forums.unrealengine.com/t/how-to-detect-a-line-break-inside-a-character-array-from-string-or-inside-a-string/616913/2 "2022-09-23T15:41:07Z")

</div>

Hello! I’m probably late but I’ll drop this img here in case it helps someone 😃  
 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/9/f/7/9f7e1089069ad56682f7dc2b645979e2d5023d59.png)
