Jump to content

FAQ - How do I backup my track plan and locomotives in RailMaster.


Guest Chrissaf

Recommended Posts

Backing up your RailMaster ‘user generated’ data is described in the RailMaster 1.74 user manual on page 132. If you have RailMaster Pro, then Pro includes a built in ‘backup’ and ‘restore’ utility and this should be used instead.

For RailMaster ‘Standard Edition’ users, then the backup function has to be performed manually as instructed on Page 132.

To make this manual backup process a little easier I have written a ‘Batch File’ that can be used to automate this manual backup process. Thus this FAQ has been written to document my DIY batch file and provide guidance on how to recreate it yourself.

My batch file takes the backup process documented on Page 132 a little further and not only backs up the files suggested on Page 132, but also backs up a further two key files:

Railmaster.ini & Activate.dat

The Activate.dat file contains the data that was used to originally activate the RailMaster key and saves a lot of grief when transferring RailMaster to a new PC.

Note that the file Groups.dat is only present in RailMaster if Groups have been configured. If no Groups have been configured then this file will not exist.

A batch file is basically a text file that contains a sequential listing of DOS [Disk Operating System] commands and runs as a Windows ‘Command Prompt’ Window. A batch file can be written using Windows Notepad, but instead of giving the saved file a .TXT file extension it is given a .BAT file extension. The .BAT file extension tells Windows to treat the file as a ‘program’.

When my RMBackup.bat file is run, a command prompt Window opens and displays this screen.

forum_image_610e91b2f30a6.png.0fb3c612e108c5116a2a654b2b148664.png

The displayed screen is basically a MENU that allows you to select a function to invoke.

Typing 3 followed by ENTER [RETURN] key closes the Command Prompt window.

Typing 2 followed by ENTER [RETURN] key creates the ‘RMBackup’ folder in the root of the C: drive where the backed up files will be stored.

Typing 1 followed by ENTER [RETURN] key makes copies of the RailMaster ‘User Generated’ files and saves them to the C:RMBackup folder. It then opens the C:RMBackup folder in Windows File Explorer to give visual confirmation that the copy process has been completed.

The creation of the backup folder [Typing 2] only needs to be performed the very first time you run this batch file utility. Once the backup folder has been created it will stay created until such time that you manually delete it.

There is no ‘RESTORE’ function with this batch file utility. This is because restoring the previously backed up files requires them to be copied to the RailMaster program folder. This folder is a Windows ‘System’ folder and is security protected from being written to by a batch file process. Therefore to restore any ‘backed up’ files you would need to use Windows File Explorer to manually copy them back from the C:RMBackup folder into the RailMaster program folder and acknowledge the Windows UAC [user Account Control] security prompts.

How to create your own copy of my batch file.

This batch file is written for 64bit Windows 7, 8 & 10 versions and will not work with 32bit Windows XP / Vista versions without modification.

Open Windows ‘Notepad.exe’.

Copy and paste the following lines of text after the horizontal line into Notepad, then save the file as RMBackup.bat onto your PC Desktop. Double clicking the saved file on the Desktop will run it.

Note I have tested the copy and paste of the batch file text below into Notepad and tested its operation. The forum does however end up pasting the text into Notepad formatted with additional line gaps. These can be left in-situ, but personally I would edit the text pasted into Notepad to remove the excess line gaps.

-----------------------------------------------------------------------

ECHO OFF

CLS

:MENU

CLS

ECHO.

ECHO ...............................................

ECHO PRESS 1 OR 2 to select your task, or 3 to EXIT.

ECHO ...............................................

ECHO.

ECHO 1 - Back up RailMaster Data Files.

ECHO 2 - Create 'RMBackup' folder [do this only once, the first time used].

ECHO 3 - EXIT.

ECHO.

SET /P M=Type 1, 2 or 3 then press ENTER [RETURN]:

IF %M%==1 GOTO BACKUP

IF %M%==2 GOTO CREATE

IF %M%==3 GOTO EOF

:BACKUP

CD C:Program Files (x86)Railmaster

COPY resource.mdb C:RMBackupresource.mdb

COPY *.pln C:RMBackup*.pln

COPY *.prg C:RMBackup*.prg

COPY Groups.dat C:RMBackupGroups.dat

COPY railmaster.ini C:RMBackuprailmaster.ini

COPY activate.dat C:RMBackupactivate.dat

START C:Windowsexplorer.exe /e,C:RMBackup

GOTO MENU

:CREATE

MD C:RMBackup

GOTO MENU

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
  • Create New...