Jump to content
Sign in to follow this  
Diana (Cda)

Simple backup scripts.

Recommended Posts

Diana (Cda)

I feel daring enough to contribute something. I've been backing up files with fantastic freeware app for years but finally stopped some time ago when frustrations with drive letters became too much. With new, less than year old, WinXP and needing flexible system for backing up from USB flash drive, the freeware app just couldn't keep up. And I've not found a truly portable one to do the job. Most so-called portables are just standalones and screw up with the drive letters on different host machines every time!

So in my backup destination folders, just dumped these scripts in. A miracle freeware called FileBox that works as a great standalone, allows me to go to any of my backup folders with a mouse click so they're easy to get to in a flash. Double-click the script, wait for the new copied date- and time-stamped folder then rar it up with WinRAR (start menu backup one worked better, it seemed with DirMove to change name, for some reason. That's only exception.).

I know there are probably a thousand ways to do this and probably nearly a thousand ways to do this better, but this works for me and it's at my level of knowledge. Hope someone else finds them of use, even if to just get an idea from them, perhaps <g>.

Place each backup script, if you use them with the code unaltered re destination folder, in the BACKUP folder for each situation.

Backing up the start menu:

; AutoIt 3x
#include <_PartitionLetters.au3>     ; my UDF that replaces all drive letters
#include<_WEReplacement.au3>     ; references a Windows Explorer replacement program
AutoItSetOption("WinTitleMatchMode", 2)     ; this allows partial window titles to be valid!
#NoTrayIcon     ; AutoIt's icon doesn't show in systray
TraySetIcon("Shell32.dll", 146)     ; changes the icon displayed in the systray

#Include <Date.au3>
; Short day of the week, i.e., Monday = Mon
$ShortDayMyFormat = StringMid("Sn,Mn,Tu,Wd,Th,Fr,Sa", StringInStr("SunMonTueWedThuFriSat", _DateDayOfWeek(@WDAY,1) ), 2)

SplashTextOn("WAIT ...", @CRLF & "Please wait while the process backs up all the files." & @CRLF,"350","50","250", "250", "Comic Sans MS","12","10") _
        ;  Make sure a "SplashOff()" is at end to turn off the splash screen. _
        ;  width, height, x pos, y pos, "fontname", "fontsz", "fontwt"

$sourceFolder = @UserProfileDir & "\Start Menu"
$destinationFolder = @ScriptDir & "\BKPfldr- StartMenu"
DirCopy($sourceFolder, $destinationFolder, 8)


DirMove(@ScriptDir & "\BKPfldr- StartMenu", @ScriptDir & "\BKPfldr- StartMenu- " & _
    @YEAR & "." & @MON & "." & @MDAY & "." & $ShortDayMyFormat &  ", " & @HOUR & "h" & @MIN & "m" & @SEC & "s", 0)

Beep(1000, 50)
Beep(1500, 50)
Beep(1750, 50)

SplashOff()     ;  turns off Splash...On(...) above.


More experienced users will get the idea right away, I think.

Hope that helps. Be gentle, pls. First time, I think, that I'm contributing something, no matter how modest. muttley

Share this post

Link to post
Share on other sites
Diana (Cda)

In case I wasn't clear, these scripts have worked so far even off of USB flash drive but interested if anyone has problems. I don't know how good I'll be to fix anything but hoping that my experiences on different machines will translate well to other's machines in terms of the scripts above being generic enough to work anywhere. That's been the case for me so far.

I use a similar approach to default template and toolbar files that I back up. The only "trouble" I've found with those is if any default source folder name is different. i.e., the only case I have right now is re the WordPerfect app data folder. I have WordPerfect 10 at home and at office they have WP12, I think it is. Folder at home has a folder named "10" in the folder path and the one at office has "13", or some such. Why 13 vs 12, beats me, but there you have it. In that case, all I did was create a "work" version of the script since I always use latest versions of default templates and toolbar files where path has correct folder name to the source folder. I just click on the work version when at work and the home version when at home.

For Excel and Word, etc., which I have similar backup scripts for, no worries as paths are identical. Only had to change the Excel toolbar file name from Excel.xlb to Excel11.xlb from the recent upgrade of Office 2000 to 2003 which is what they had at office. I didn't provide these backup scripts here, but can do so if anyone is at all interested.

In most cases, if you use this type of backup approach, versions are usu. the same or different versions can use the same default files (i.e, both WordPerfects above use the same default template file with no problems). i.e., any changes I make to my firefox bookmarks doesn't matter. I use the latest backup one no matter what.

Haven't found a good synchronizer yet though I've tried tons, so I must manually change files in each locale from latest backup. But fortunately, with regards to default toolbars and templates, I only make very periodic changes anyway. <g>

Cheers. muttley

Edited by Diana (Cda)

Share this post

Link to post
Share on other sites

i noticed you said you havn't found a good synchronizer yet. i take it you mean file/folder synchronization?

best one i have used is the microsoft robocopy tool (part of win serer 2003 resource kit: http://www.microsoft.com/downloads/details...;displaylang=en also comes with Vista/server 2008)

robocopy source dest /mir will replace the destination with the source... i use it for all my backup needs onto usb :)

i've also setup my usb autorun.inf file so as soon as its plugged in it does a sync, incase i forget to...

Edited by boomingranny

Share this post

Link to post
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
Sign in to follow this  


Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.