New NotePad Document

Okay, im making a program where you enter some text, and then the text you entered is stored in a new NotePad Document and stored In My Documents. Does anybody know how to do this? Thanks guys :)
You can use fstream
example
1
2
3
4
5
6
7
8
9
#include<fstream>
using namespace std;
ofstream outfile("C:\\Documents and Settings\\arthur\\My Documents\\outfile.txt");//this is your output 
//file
int main()
{
	outfile<<"blah blah";//for testing
	return 0;
}

Note that when you must use '\\' instead of '\' because one slash in c++ doesn't mean slash!
Sorry for my bad explaining :)
Hope i help you
Topic archived. No new replies allowed.