in reply to Perl for windows file parsing
Here's an outline of your program:
open directory handle for E:\temp while the handle returns filenames match filename against spec. - capture year and day of year. if name does not match, skip to the next file. test for existence of target path. if does not exist, create it. move file to new location.
Between the outline above and Fletch's pointers to docs you should be able to put something together.
You should also take a look at next. perlretut will help you match the filenames to your spec and capture the information you want.
Once you have a script that works, you can create an entry in Scheduled Tasks.
Also worth mentioning, many tutorial neglect to suggest using strict, warnings and diagnostics. I strongly recommend using all 3 when starting out. diagnostics can be skipped after you've learned to interpret Perl's compiler alerts.
TGI says moo
|
|---|