You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@habibasorour This works fine with a different filename.
However, I don't think changing the file name is the way to go. Since we do not know how many times the code will be run, and there is too much detail already in this short book. I would delete this listing entirely and fix the prose to make the next listing make sense.
@pearcej looking at the code in this section, every <datafile> tag has the name myfile so i think this is what is causing the issue.
This subsection is about writing a file in Java, and I think this listing is the main part of the whole section. I want to try to change it to a new name instead of just myfile and call it like myfilenew so that it is just unique for this and I think this might solve it. What do you think?
Activity
pearcej commentedon Aug 5, 2026
@habibasorour This works fine with a different filename.
However, I don't think changing the file name is the way to go. Since we do not know how many times the code will be run, and there is too much detail already in this short book. I would delete this listing entirely and fix the prose to make the next listing make sense.
habibasorour commentedon Aug 5, 2026
@pearcej I will work on this
habibasorour commentedon Aug 5, 2026
@pearcej looking at the code in this section, every
<datafile>tag has the name myfile so i think this is what is causing the issue.This subsection is about writing a file in Java, and I think this listing is the main part of the whole section. I want to try to change it to a new name instead of just
myfileand call it likemyfilenewso that it is just unique for this and I think this might solve it. What do you think?pearcej commentedon Aug 5, 2026
This is a fine idea, but I still think we should remove the earlier code because of the possibility of running the code multiple times.