How are you doing the file property updates? Use BatchUpdate.
I am going to a folder and finding all files in the folder and the subfolders and making a list and recursively checking out, and updating. when all of the files are updated I use the same list to check the files in.
I am not able to use batch update as based on file name the properties can vary, that and EPDM has an automatic transition in the workflow for this process that will not work with batch checkin, I have tried a few different ways and all of them have issues thus far.
You can use Process Explorer to determine what process is holding the file. If it is your own application, you are probably doing something wrong. It's impossible to know without seeing some code. Is SolidWorks open when you are doing this? Are any of the problem files open in SolidWorks?
I have an add-in that does the same sort of thing (check out, update properties, check in, rename and move) and I use BatchUpdate and BatchUnlock. BatchUpdate doesn't require that all the files get the same property changes. You set variable values on a per file basis using SetVar.