I don't know what to do at SSCCE. When I paste my Java code there, I get a lot of import errors. I have no idea what I have to do there, so I'll quickly give you my Github link again and hope that you can help with it.
the code snipet can be found in the MenuSchreiber class
I've attached a few pictures that show what the output should look like. Since I would create too many files in this way (numbered filenames), I want the first file to be labeled again and again.
Again to the problem: The array text, which is passed as a parameter, arrives correctly, but is only written once to a file. Then I don't get this file rewritten in a program run.
It seems as if the menuBlanco2 file is still accessible.