I am using the following code to create a new folder in the existing "games" folder, but this is not just the folder Is making. Ensure that you have a game code in which Also make sure your The following part of the code should be made the specified directory. {QDebug () QDir dir ("C: / Games / MyGame"); If (! Dir.exists ()) {dir.mkdir ("C: / Games / MyGame"); } Other {qDebug () & lt; & Lt; Dir.absolutePath () + "exists"; }
C: / < / Code> [Check the program to see if QDir () ("C: / Games /) is returning true.]
C: / folder
is a file in your name No, because if you have a file with the same name, the existing folder will also return the function even if it exists, .and
mkdir will be incorrect!
If present ("C: / Games / MyGame"))
Comments
Post a Comment