For moving to a new computer or doing system refreshes, this helps to save and restore the Weather Watcher settings. At least on my Windows XP SP2 system.
WWBackup.cmd[code]@echo off&title Weather Watcher settings backup&mode CON Lines=18 Cols=77
:: Modified version of the COMODO 2.4 firewall backup script
set BKUPfolder=%SYSTEMDRIVE%\Documents and Settings%USERNAME%\DESKTOP\WWBackup\
set REGkey=HKEY_CURRENT_USER\Software\VB and VBA Program Settings\Weather Watcher
set BKUPfile=WWsettings.REG
if not “%1” == “” set BKUPfolder=%1
if not “%2” == “” set BKUPfolder=%1 %2
if not “%3” == “” set BKUPfolder=%1 %2 %3
cls
echo.
echo ***************************************************
echo The Weather Watcher settings will be backed up to:
echo “%BKUPfolder%%BKUPfile%”
if exist “%BKUPfolder%%BKUPfile%” for %%i in (“%BKUPfolder%%BKUPfile%”) do
echo Date/time of last backup: %%~ti
echo.
echo To Restore the “%BKUPfile%” file’s settings back into the Registry:
echo 1. Shutdown Weather Watcher
echo 2. Open RegEdit and delete the key
echo HKEY_CURRENT_USER\Software\VB and VBA Program Settings\Weather Watcher
echo 3. Close RegEdit
echo 4. Finally dbl click on the backup .reg file.
echo.
echo NOTE: You may also need to reboot the PC!
echo ***************************************************
echo.
echo To start press Enter. To quit press the “x” button on this window
pause >nul
cls
if not exist “%BKUPfolder%%BKUPfile%” goto :new
goto :archive
:archive
echo Clearing oldest backup - please wait …
del “%BKUPfolder%Prior%BKUPfile%” >nul
echo Storing previous backup - please wait …
copy “%BKUPfolder%%BKUPfile%” “%BKUPfolder%Prior%BKUPfile%” > nul
echo Archiving current rule set - please wait …
REGEDIT /E “%BKUPfolder%%BKUPfile%” “%REGkey%”
goto :end
:new
cls
echo.
echo Creating folders - please wait …
echo.
md “%BKUPfolder%”
md “%BKUPfolder%Prior”
echo Archiving registry keys - please wait …
REGEDIT /E “%BKUPfolder%%BKUPfile%” “%REGkey%”
copy “%BKUPfolder%%BKUPfile%” “%BKUPfolder%Prior%BKUPfile%” >nul
goto :end
:end
echo.
echo DONE!!!
echo.
echo Press any key to end
pause >nul
[/code]
When cutting&pasting be careful of line wrapping of the CMD lines. The set REGkey in particular. It’s all one line.
hth
BTW The Backup file could be smaller if the WW Registry key could be structured differently. A subkey for all the Setting keys and a subkey for all Forecasts data keys would allow the Forecasts data fields to be excluded. Since they are created each time WW does a Retrieval there is no real need to back them up.
NB When copying and pasting the above script be sure there is no extra space or blank at the end of the three set commands at the top of the script in the version you save. Either Windows or the board’s forum sw is adding it in some cases which results in the script failing. :sad:
Update: Revised the script’s Restore steps.