Plan Documentation Journal
Small Victories, Apr 10, 09
- Today I discovered the joy of accomplishing small tasks successfully in computer programming.
- My program initially only scanned for file names in a folder that is being shared, so you know the file names and nothing more.
- Then I tried to scan the files to break down the whole contents of a file into a 10-digit code. That way, I could compare the 10-digit codes to check if a file has been modified between scans of the file every few minutes. After a little research I did this successfully. Now, the whole contents of MyPaper.doc can be broken down into '4235273824,' so if any changes are made to that file, that little number will be different, and I'll know it's been changed.
- So now I know if an individual file's been changed. But what about noticing if all of the files in a folder are changed? Do I need to scan every file and compare each one to see if there have been any changes? The small victory I had today was answering 'no' to that question.
- I figured out a way to cumulatively add the 10-digit codes for each file into a single code that represented the whole set of files. That way, I can compare whether the whole set of files has changed or not, and if so, then scan for individual changes, but ignore it if nothing has changed.