# How to commit text on a multi-line textbox ?

**URL:** <https://forums.unrealengine.com/t/how-to-commit-text-on-a-multi-line-textbox/325454>\
**Category:** UI\
**Tags:** textbox, unreal-engine, Widget, UE4, Blueprint, question\
**Created:** [July 16, 2015, 8:39am UTC](https://forums.unrealengine.com/t/how-to-commit-text-on-a-multi-line-textbox/325454 "2015-07-16T08:39:12Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![rXp](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@rXp](https://forums.unrealengine.com/u/rXp)\
**Post date:** [July 16, 2015, 8:39am UTC](https://forums.unrealengine.com/t/how-to-commit-text-on-a-multi-line-textbox/325454/1 "2015-07-16T08:39:12Z")

</div>

Hello,

I had a text box but I needed text wrapping so I changed it for a multi-lines textbox.  
My issue is that now ENTER makes a newline and does not commit. I want to change that so that ENTER commits and UPPER+ENTER does a newline. I tried adding ENTER as en input but it seems to be caught and blocked by the textbox.

What can I do ?

---

<div class="post-metadata">

**Author:** ![rXp](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@rXp](https://forums.unrealengine.com/u/rXp)\
**Post date:** [July 16, 2015, 9:51am UTC](https://forums.unrealengine.com/t/how-to-commit-text-on-a-multi-line-textbox/325454/2 "2015-07-16T09:51:46Z")

</div>

I found the answer :

Override the OnPreviewKeyDown in the Widget blueprint (HUD for me) it will get the input BEFORE the child so you can do whatever you want with it. If you reply to this event with an Handled eventreply it will not be sent to the children if you reply Unhandled then it will be sent to the children.

 ![50413-2015-07-16+11_47_19-46.126.130.142+-+remote+desktop+connection.jpg](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/9/3/2931a1de15f7c026ea17f2aea230c377a915dd79.jpeg)

---

<div class="post-metadata">

**Author:** ![Bob3DGames](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Bob3DGames](https://forums.unrealengine.com/u/Bob3DGames)\
**Post date:** [January 15, 2017, 7:36pm UTC](https://forums.unrealengine.com/t/how-to-commit-text-on-a-multi-line-textbox/325454/3 "2017-01-15T19:36:48Z")

</div>

I had this problem and this solves it for me too. Thanks!

Since I’m here though, I’d thought I’d just update the solution by mentioning that with more recent versions you can have more than one return node (which have a handled/unhandled checkbox). This would simplify the blueprint script in the solution above, i.e. you no longer need the gubbins in the red boxes.

---

<div class="post-metadata">

**Author:** ![EniGmaa](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@EniGmaa](https://forums.unrealengine.com/u/EniGmaa)\
**Post date:** [April 6, 2017, 8:40pm UTC](https://forums.unrealengine.com/t/how-to-commit-text-on-a-multi-line-textbox/325454/4 "2017-04-06T20:40:26Z")

</div>

thanks so much for this fix mate it was drving me crazy.

---

<div class="post-metadata">

**Author:** ![anon17187051](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anon17187051](https://forums.unrealengine.com/u/anon17187051)\
**Post date:** [January 31, 2018, 3:32pm UTC](https://forums.unrealengine.com/t/how-to-commit-text-on-a-multi-line-textbox/325454/5 "2018-01-31T15:32:23Z")

</div>

Sorry to bump an old question, but i have the same issue and i don’t know how to make an input to commit the changes inside the multi line text box, how should i implement this?

---

<div class="post-metadata">

**Author:** ![MarcoMariaRossi](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/marcomariarossi/32/1069093_2.png) [@MarcoMariaRossi](https://forums.unrealengine.com/u/MarcoMariaRossi)\
**Post date:** [July 17, 2019, 12:21pm UTC](https://forums.unrealengine.com/t/how-to-commit-text-on-a-multi-line-textbox/325454/6 "2019-07-17T12:21:03Z")

</div>

I’m stuck too, how do you call the event to actually commit the text ?

---

<div class="post-metadata">

**Author:** ![MrLloyd88](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@MrLloyd88](https://forums.unrealengine.com/u/MrLloyd88)\
**Post date:** [July 2, 2021, 1:19pm UTC](https://forums.unrealengine.com/t/how-to-commit-text-on-a-multi-line-textbox/325454/7 "2021-07-02T13:19:56Z")

</div>

If you use “set focus to game viewport” instead of whatever “send message f” is it will automatically submit as the widget has lost focus and that is default functionality.

---

<div class="post-metadata">

**Author:** ![Kaspi](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Kaspi](https://forums.unrealengine.com/u/Kaspi)\
**Post date:** [September 30, 2021, 3:13am UTC](https://forums.unrealengine.com/t/how-to-commit-text-on-a-multi-line-textbox/325454/8 "2021-09-30T03:13:06Z")

</div>

Thanks, helped

---

<div class="post-metadata">

**Author:** ![DevNexy](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@DevNexy](https://forums.unrealengine.com/u/DevNexy)\
**Post date:** [May 25, 2023, 3:00am UTC](https://forums.unrealengine.com/t/how-to-commit-text-on-a-multi-line-textbox/325454/9 "2023-05-25T03:00:51Z")

</div>

Thank you

---

<div class="post-metadata">

**Author:** ![Luckboy](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Luckboy](https://forums.unrealengine.com/u/Luckboy)\
**Post date:** [August 11, 2023, 5:04am UTC](https://forums.unrealengine.com/t/how-to-commit-text-on-a-multi-line-textbox/325454/10 "2023-08-11T05:04:34Z")

</div>

This worked great =) Thanks man!
