i added a edit box in my programm, and searching for a possibillity to get always the actual text written down there when a button has been clicked.
My code so far:
Code: Select all
gui::IGUIEditBox *_pSubmitNameBox = _pGUIEnvironment->addEditBox(L"", core::rect<s32>(45,148,368,192),false,_pBackgroundRootObject,3);
const wchar_t *objectToSaveText = _pSubmitNameBox->getText();
if i click a button this will be executed::
Code: Select all
std::cout <<objectToSaveText << std::endl;
The output i get is unfortunatly not the text written down, it is the position where the pointer is saved.
I tried also:
Code: Select all
std::cout <<*objectToSaveText << std::endl;
How can i get the Text?