You are here

SyncBack Batch File

7 posts / 0 new
Last post
Jace
Offline
Last seen: 16 years 10 months ago
Joined: 2006-02-16 12:59
SyncBack Batch File

Here is a copy of what I am using with SyncBack. It backs up the existing settings runs syncback and then restores the previous settings. If there are no existing settings it still works fine but gives some error messages. Let me know any suggestions as this is my first batch file and I am still learning. I tried registry rapper first but it didn't backup the existing registry settings so if I use it somewhere where it is already installed they will loose all the profiles.

@ECHO OFF
REM **********************************************
REM SyncBack Startup
REM **********************************************

REM Try to export the existing SyncBack registry Settings to SyncBack_Exist.reg
REG EXPORT HKEY_CURRENT_USER\Software\MJLSoftware SyncBack_Exist.reg

REM Delete the existing SyncBack registry settings
REG DELETE HKEY_CURRENT_USER\Software\MJLSoftware /f

REM Checking if a specific reg file exists if so add it to the registry
if exist SyncBack_%computername%.reg regedit /s SyncBack_%computername%.reg

REM Starting SyncBack
REM STart SyncBack then wait for it to exit before continuing
start /WAIT syncback.exe

REM Exporting Portable Settings for next session
REG EXPORT HKEY_CURRENT_USER\Software\MJLSoftware\ SyncBack_%computername%.reg

REM Deleting the Portable Settings from the registry
REG DELETE HKEY_CURRENT_USER\Software\MJLSoftware /f

REM Check if there were any existing settings if so add them to the registry
if exist SyncBack_Exist.reg regedit /s SyncBack_Exist.reg

REM Check if the existing registry setting file is still present if so delete it
if exist SyncBack_Exist.reg DEL SyncBack_Exist.reg

exit

Jace
Offline
Last seen: 16 years 10 months ago
Joined: 2006-02-16 12:59
Windows98

I tried to run this on a windows 98 machine and it wouldn't work, it only generates bad command error messages. Anybody have any suggestions?

Jace
Offline
Last seen: 16 years 10 months ago
Joined: 2006-02-16 12:59
bump

Anybody

Mr-Fly
Offline
Last seen: 11 years 3 months ago
Joined: 2006-03-11 08:13
Windows 98 has no built in

Windows 98 has no built in reg.exe

Thats why this will not work on win98

Mr-Fly
Offline
Last seen: 11 years 3 months ago
Joined: 2006-03-11 08:13
One tip for you.

One tip for you.
To hide the command line window during the execution of syncback, you can use a tool called cmdow (search google)
You can replace the start call by:
cmdow @ /HID
start /wait syncback.exe
cmdow @ /VIS

This will hide the command line short before the start of syncback and show the command line right after exit Smile

Greets
Thorsten

edit: the next version of syncbackSE will have .ini support rather than using the registry.

Mr-Fly
Offline
Last seen: 11 years 3 months ago
Joined: 2006-03-11 08:13
Version 4.1

Hi.

The next version of SyncBackSE will not use the registry anymore and does not require any DLL's to be registered anymore.

I am using a beta already and it is really great.
So stay tuned, when it will be released.

Kind Regards
Thorsten

azjerry
Offline
Last seen: 7 years 3 months ago
Joined: 2005-12-09 12:42
too bad it's not the free version

of SyncBack. It seems destined to stay forever at version 3.something

Topic locked