Ok, so my problem is that for some reason my fstream (named "myfile") is inaccessible in my cpp file. I will show you the code for the involved methods and the imports I have in the cpp file.
Ok, that got rid of the accessibility issues, but my program is still crashing when I try to save the file. Is anything obviously off about this code? I'm new to c++, so I might be missing something basic.