ScottWisker
Mechanical
- Jan 31, 2007
- 15
I'm trying to clean our server ...
I've written code that searches a given location for assembly files and returns all of the components referenced within.
I then compare filenames to our "vaulted" parts and return a list of matches. I was then using File Size to determine if the files were actually the same or just had the same name. However, the File Size of any given component seems not to be the most stable element to use as it can change slightly based on it global path. I then tried using the Last Modified Date, but this can also change when an assembly is rebuilt.
The goal was to replace the copies within the assembly files with the references back to the vault and delete the copies.
Does anyone know of a property accessable from the Document Manager API that could confirm that two components are identical?
PS
I am aware of the "compare geometry" function within the Utilities, but would rather not go that route.
Thanks,
wisker
I've written code that searches a given location for assembly files and returns all of the components referenced within.
I then compare filenames to our "vaulted" parts and return a list of matches. I was then using File Size to determine if the files were actually the same or just had the same name. However, the File Size of any given component seems not to be the most stable element to use as it can change slightly based on it global path. I then tried using the Last Modified Date, but this can also change when an assembly is rebuilt.
The goal was to replace the copies within the assembly files with the references back to the vault and delete the copies.
Does anyone know of a property accessable from the Document Manager API that could confirm that two components are identical?
PS
I am aware of the "compare geometry" function within the Utilities, but would rather not go that route.
Thanks,
wisker