How can I get string from Widget's TextBox and set to variable in c++ class?

Hello,
I want to get string from widget text box and set this string to a variable in c++ class .
It can be name of player on start the game.
Do you know about tutorial with this topic or can u explain me how to do?
Thanks for help.

Hi ! If you allready have your widget pointer , cast it to UEditableTextBox and then:

	UEditableTextBox* box;
	box->SetText(FText::FromString(TEXT("your text")));
	FText text = box->GetText();

don’t forget the include : #include “EditableTextBox.h”