Japanese letters in file path converted into question mark(?). How can i deal with them?
Unsolved
General and Desktop
-
Hi,
I have a folder in Japanese language like this "E:/QT projects/Path_in_Chinese/ランゲージ/ランゲージ/New folder/testbuilding.IVE".
When i print the path and check existence of file then the output is:-
code:
QString fileName1 = "E:/QT projects/Path_in_Japanese/ランゲージ/ランゲージ/New folder/testbuilding.IVE";
QFile f1(fileName1);
qDebug()<<fileName1<<"\nExist: "<<f1.exists(); -
Output:
"E:/QT projects/Path_in_Japanese/?????/?????/New folder/testbuilding.IVE"
Exist: true
How can i deal with these types of path. Thanks in advance.
-
-
@Pardeep said in Japanese letters in file path converted into question mark(?). How can i deal with them?:
qDebug()
This is simply debug output, it can depend on the encoding in the console. Try
qDebug()<<fileName1.toUtf8()<<"\nExist: "<<f1.exists();