User Activity

  • Posted a comment on discussion Troubleshooting on Dev-C++

    hi, i have a problem, im starting to use files on c++, and i want to make a program that you give an id, and it first search for it on the file, if it isnt found then you can create a new id and add data to it, the thing is that i think its never saving because the output file is always 0kb #include <iostream> #include <fstream> using namespace std; struct stPeople{ int id; char name[15]; }; int main(){ stPeople people={0, ""}; fstream file; file.open("data.txt",ios::in|ios::app|ios::binary); if(!file){...

View All

Personal Data

Username:
lordofthecube
Joined:
2018-04-21 17:17:40

Projects

  • No projects to display.

Personal Tools