I want write a program that will syncronize files between two directories.. Suppose (in windows) im copying file(s) into the "from" directory and my program runs to sync the files, I dont want it to try to sync a file that im copying into the "from" directory.. Is there a way to tell if the file is "being copied"?

Is a file thats "being copied" read-only? If so, can I just try to open the file read-write in my program and if it fails just skip that file?

Let me know if this doesnt make sense or if more info is needed..