Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Creating Folder Inside Newly Created Folder

Status
Not open for further replies.

oop94

Programmer
Jun 14, 2005
31
0
0
US
I am trying to create a folder inside another newly created folder.
First, I create a folder named 'newvolt' using the _mkdir function:
Code:
_mkdir(newvolt);
Next, I try to create a subfolder named 'SG019810002-500' inside the folder 'newvolt' using the _mkdir function once again:
Code:
_mkdir("h:\\newvolt\\SG019810002-500");
'newvolt' is created successfully, but 'SG019810002-500' is not. MSDN describes the _mkdir as
Code:
int _mkdir( const char *dirname );
with dirname as the path for new directory. Here's the link: Can someone please help me figure out how to complete this seemingly simple task? Thanks for any help!
 
_mkdir(newvolt) - what's newvolt variable contains?
If you have _makedir("h:\\newvolt"), you may create _makedir("h:\\newvolt\\.....").
What's a problem?
Be careful: _mkdir("nevolt") creates a new dir in the current directory.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top