Stephan van Hulst wrote:The problem is that when you open the file, an exception is thrown (probably because the file wasn't found), but then you catch the exception and continue with closeFile(), even though input is still set to null.
Why would you want to close the file if you didn't manage to open it in the first place?
Anyway, you need to start improving your code style, as we have mentioned in other topics. Your code will be easier to debug if you follow the tips we have given you.
Campbell Ritchie wrote:Hahahahahahahahaha!
Unfortunately that doesn't teach you what the real problem was. Go back to the old image and work out the differences from the new image and see if you can find an explanation for your earlier problems.
Campbell Ritchie wrote:Where are you declaring the text box (line number, please)?
How are you adding it to the top‑level container (again, line number, please)? What layout does the container you are adding it to have? If border layout, are you adding anything else to that container? If flow layout, what are the sizes of the container and its child components? I don't like flow layout because of its propensity to change alignments when resized and because components can vanish if the container shrinks.
Campbell Ritchie wrote:Well done Please show us what correction worked.