본문 바로가기
Development/QT

QString to char array 배열 변환

by qWooWp 2021. 2. 16.
반응형

 

QString to char array

QString src;
char dest[100];
sprintf(dest, "%s", (const char*)src.toStdString().c_str());

 

char array to QString

QString dest;
char src[100];
dest = QString(src);
dest = QString::fromUtf8(src);

 

 

반응형

댓글