for my projet 'Arcis', i make that :
(char*)this->login->getText();
but with this code, i have just the first caracter of the line login->getText() !
why ?
Convert a wchar_t* to char* problem
a string is an array of multiple characters
you only get the first character if you try it like you did.
if you like to convert these strings you have to do this several times for every letter.
string->size()
delivers you the length of the string
with the help of a for instruction like
for(i=0;i<size;i++)
{
string1 = string2;
}
it should work.
you only get the first character if you try it like you did.
if you like to convert these strings you have to do this several times for every letter.
string->size()
delivers you the length of the string
with the help of a for instruction like
for(i=0;i<size;i++)
{
string1 = string2;
}
it should work.