Thanks!
It is just as you say, the problem is somewhere else, I think I found it!
I read all the files (Images) from a directory to a list. This list is used for viewing images on screen, do selection of images for editing and so on. One function is to move images to other directors (category ).
I think the problem is that after reading the images to the list, they are kept open. I can see this among other things in Windows Explorer!
If I try to delete the file in Windows Explorer, I get the following message:
The message below is in Swedish as picture, it says:
“ The file is used
the operation cannot be completed because the file is open in the Java ™ Platform SE binary
Close the file and try again.”
I need to change the strategy for moving files and simultaneously visualize the movement on screen!
I guess I can't close files in runtime!