I am new to Java.
While I am trying to copy a file using "File.copy" method in java. The process end without errors.
But the file I need to copy is created with only one weired character (I think it is an file end character). and it has no content other than it.
Here is my source code,
var sourceFile = new File("mySourceFile.txt")
var destinyFile = new File("myDestinyFile.txt");
Files.copy(sourceFile.toPath(), destinyFile.toPath());
I solved the problem.
The problem is that there are outputstreams already open for the same destiny file I have to.
So it File.copy() method cannot write on the file.