Jump to content

Script to automatically archive files over 50MB?


StOnge
 Share

Recommended Posts

Hi. I've searched on these forums for awhile now, and haven't found any threads that answer a question quite like mine. If something like this inquiry has been posted before, then I apologize.

I was wondering if there is a way to write a script that will automatically archive (using WinRAR or WinZip) files in a directory that are over 50MB. For example, have a script scan a folder until it sees a file over 50MB, then launch WinRAR, archive that file, and then continue to scan until it comes across another file greater than 50MB, archive it, etc.

My experience with AutoIT is limited, and this task is beyond my skill with scripting. Any leads or help would be very much appreciated.

Let me know if additional information concerning my question or situation is needed, and I will post it in this thread.

Thank you very much for your time, and thank you in advance for your help.

www.stonge.com

Link to comment
Share on other sites

Hi. I've searched on these forums for awhile now, and haven't found any threads that answer a question quite like mine. If something like this inquiry has been posted before, then I apologize.

I was wondering if there is a way to write a script that will automatically archive (using WinRAR or WinZip) files in a directory that are over 50MB. For example, have a script scan a folder until it sees a file over 50MB, then launch WinRAR, archive that file, and then continue to scan until it comes across another file greater than 50MB, archive it, etc.

My experience with AutoIT is limited, and this task is beyond my skill with scripting. Any leads or help would be very much appreciated.

Let me know if additional information concerning my question or situation is needed, and I will post it in this thread.

Thank you very much for your time, and thank you in advance for your help.

Hi,

First use Zip udf in pure autoit in exemple script forum and filegetsize

Simple example

if filegetsize("file")>50000 then
archive()
endif
Link to comment
Share on other sites

  • 2 weeks later...

Hi,

First use Zip udf in pure autoit in exemple script forum and filegetsize

Simple example

if filegetsize("file")>50000 then
archive()
endif
Does that imply that I know the name of the file? What I would ideally like to do (not sure if this is possible) is have the script scan an entire drive and archive every file over 50MB.

www.stonge.com

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...