You can create it easily using
System.IO.Directory.CreateDirectory(AppDomain.CurrentDomain.BaseDirectory + "\\MyFolder");
But you need to take care of some things .
As you application will run on server and client will try to create button on server, then Client will receive
"Access Denied" error as They does not have sufficient permission to write on server.
What you need to do, You can give
Write access to the folder where you want to create the sub folder to every one, which I personally think not a good idea or Create a separate
application pool for your application, Change the Identity of Application pool to
"Local System" Which having
full permission to write on server . By default it is
"Network Service" Which having minimum permission like access.
Hope this will help you !!
Cheers !
Abhijit
Rajujrk, if this helps please login to Mark As Answer. | Alert Moderator