Valhalla Legends Forums Archive | C/C++ Programming | mkdir

AuthorMessageTime
MoNksBaNe_Agahnim
I am doing this bank project for an upcoming C++ tournement im in,

the part I am doing is they want you to be able to create a new costumer and save to a text file, be able to modify the costumer such as the customer's name, or delete the comstumer's info. I got this all to work and now im trying to get it so that the user can make a folder were all the customer's info can go into (since there can be more than one costumer) that way there are several different folders for the different people who have an account making it organized better...

But i can't seem to have it so the user inputs the name they want the folder to be called then have it make the folder by that name, i have tried things like

[code]
char fname[20];
char fname2[255];

cout << "Input account name: ";
cin >> fname[20];

strcpy(fname2, fname);
system("mkdir 'fname2' ");
[/code]

but the system function doesn't seem to work that way...

Is there a way to do this like how a user can make the name of a txt file they want?
January 16, 2004, 2:51 AM
K
how about:

[code]
mkdir("full\\directory\\path");
[/code]

Edit: I think the unix version takes a second permissions argument. Not sure.
January 16, 2004, 3:18 AM
Kp
I have to ask - why's a bank program care about costume designers?
January 16, 2004, 4:53 AM
Tuberload
[quote author=Kp link=board=30;threadid=4734;start=0#msg39758 date=1074228810]
I have to ask - why's a bank program care about costume designers?
[/quote]
That is kind of strange... I have never seen anyone rotate a word the is spelled correctly, and not spelled correctly so many times. It's almost like he has split personalities, and they just kept coming and going. One can spell, one can't.;D
January 16, 2004, 4:59 AM
MoNksBaNe_Agahnim
what do you mean Kp?
January 16, 2004, 5:27 AM
Kp
[quote author=MoNksBaNe_Agahnim link=board=30;threadid=4734;start=0#msg39735 date=1074221496]
new costumer
modify the costumer
customer's name
comstumer's info
customer's info
more than one costumer[/quote]

That's what I meant. :P You're creating costumers for the bank... :)
January 16, 2004, 3:45 PM
Zakath
Pronounce it KOSS-toom-er instead of KUSS-tuhm-er and it makes sense. :p

Costumer == someone who makes costumes...
January 16, 2004, 5:09 PM

Search