While I'm unfamiliar with TurboC++ (I use MinGW/GCC & clang/llvm), it could be a permissions issue. Compile your program and try run it as administrator manually through the file manager. If this works, tell it to write in a normal user accessible directory, such as the documents directory.