doolysw Posted September 28, 2005 Report Share Posted September 28, 2005 I'm attempting to create a macro that will move files from one directory, and archive them in another directory. Every time the macro runs, I want it to create a directory named after the curent month/day/year/hour:min and then move all the files from the source directory into the newly created directory. The trouble that I'm having is that I'm using the create folder command like this Create Folder: "f:\archive\%N1%" All I get when that runs, is a directory named %N1% under the archive folder. The variable is not being replaced. Any idea how to make this work? Quote Link to comment Share on other sites More sharing options...
joe Posted September 28, 2005 Report Share Posted September 28, 2005 Welcome to the group! You first need to set a variable with the current date/time: Date/Time: Save "yyyymmdd.hh.mm" into %T1% Create Folder: "c:\temp\%T1%" And don't forget there are characters that cannot be used in a folder or file name. \ / : * ? " < > | Quote Link to comment Share on other sites More sharing options...
doolysw Posted September 28, 2005 Author Report Share Posted September 28, 2005 Wow, thanks man you rock! Now I wanna have the macro delete any directory, and all it's sub-directories under f:\archive that are over 30 days old. I'm archiving pictures from a motion sensing webcam, and I don't wanna keep any pics over 30 days old. I'm banging my head against it now, but any suggestions would be appreciated. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.