when we create a file in c++. can we actually see it in the given folder.if yes then why cant i? when i run the program it display nothing.n no files by dat name is shown in that folder

Recommended Answers

All 2 Replies

when i run the program it display nothing.n no files by dat name is shown in that folder

I'm sure you've tested the fail bit indicators of your 'ofstream' object after your attempt to open() the destination folder and found that there were no errors.

So I can only assume you are looking in the wrong location.

Well, look through your computer and find the .cpp file with the same name as your project. Once found, the .txt, .dat, etc. file should be within the same location.

If it is not, then either you sent the file to a different location, or you did not create a file.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.