Thread: C++ question
View Single Post
Old Oct 22nd, 2006, 10:25 PM   #8
The Dark
Expert Programmer
 
Join Date: Jun 2005
Posts: 884
Rep Power: 4 The Dark is on a distinguished road
Quote:
Originally Posted by physicist View Post
exactly! thanks
now, it still doesnt work when i change // to \\
and if the string combines then it is not in a new folder just a file with a diff. name
AND i get an error if i try to specify the path as just a string...
so how can i make it so that when the user enters their name a subdir named as the string they just entered in with a .txt is made.....
Try using + to add strings together, if d is an std::string object. If it isn't you will have to add the strings together using strcat.

Also try to make your topic titles a bit more informative, we can guess that it is a "C++ question" as it is in the C++ forum. Maybe something like "how to add strings together" or "how do I get the user to input a directory". Similarly, your other topic "new question now" is just as uninformative.
The Dark is offline   Reply With Quote