Reputation: 21
I need help on how to add "everyone" to the folder's share option property using c++.
this is my code on how to create new folder
#include <direct.h>
int main()
{
mkdir("c:/scan");
return 0;
}
Upvotes: 1
Views: 1182
Reputation: 238311
According to the documentation, following should create a directory, and set permissions to give all users access:
namespace fs = std::filesystem;
fs::create_directory(path);
fs::permissions(path, fs::perms::all);
Upvotes: 2