Reputation: 63200
I have the following code, and although the call to boost::filesystem::create_directory
returns true
, I see no directory created in my project folder.
What could be the reason for this?
boost::filesystem::path dir("newdir");
if (boost::filesystem::create_directory(dir))
std::cout << "Success" << "\n";
I'm using VS2008 and Win7 Home Premium.
Upvotes: 13
Views: 35625
Reputation: 4294
Could you be looking in the wrong place for it? A quick call to cout << current_path().string() << endl;
will show you where your directory is being created.
Upvotes: 4
Reputation: 24403
You could be suffering from folder virtualization. Also try creating a directory with the full path so that you are not affected by whatever current application directory is
Upvotes: 8