The backup scheduler enables automatic backup of your invoice template and database files.
For now the backup scheduler is designed for local files only -- i.e. your invoice template and Access database file. SQL Server offers its own back up tools, as detailed on Create a Full Database Backup (SQL Server). If your SQL Server is hosted on the Internet, the hosting service provider may offer automatic backup too.
The backup scheduler built into Invoice Manager for Excel utilizes Windows Task Scheduler. Once you have scheduled your backup task, it is performed automatically on each recurring day.
Once you enabled the automatic backup, on each recurring day specified in the "When to backup" section, all files shown on the "What to backup" list will be copied to a zip package file stored in the destination folder. The zip package file will have a file name like " UIS-BackupFile-20180826-093332.zip", where "20180826" is the date when the backup is performed, and "093332" is the time (hour, minute, second).
That's all you need to know to enable automatic backup for Invoice Manager for Excel. The following section explains the underlying mechanism. You need to understand the underlying mechanism only when you want to further customize the backup process.
When the backup scheduler is enabled, Invoice Manager for Excel creates a task named "Invoice Manager for Excel Backup Task" in Windows task scheduler. To start Windows Task Scheduler, type "Task Scheduler" into your Windows 10 search box, click "Task scheduler" on the result.
Double click or tap on "Invoice Manager for Excel Backup Task" to open the property page.
As you can see Windows task scheduler offers more options and thus deep control over the task execution. For example, the task created by Invoice Manager for Excel is run only when you sign in Windows with the account you used to create the task. However on this "Invoice Manager for Excel Backup Task Properties" dialog box, you can choose to "Run whether user is logged on or not."
The "Actions" page shows what to do when the task runs. In this example, the "Action" is "Start a program", which is "UisBackup.exe" installed by Invoice Manager for Excel setup program. When UisBackup.exe starts to run, it loads the configuration file:
C:\ProgramData\UniformSoft.com\Invoice Manager for Excel\BackupSettings.xml
Here is an example of BackupSettings.xml
<?xml version="1.0" encoding="utf-8"?> <cBackupOptionsData xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"> <Enabled>true</Enabled> <DaysOfWeek>127</DaysOfWeek> <FilesToBackup>E:\inv2\aa.xlsx;E:\inv2\aabb.mdb;e:\inv2\INVOICE.xlsx;E:\NET\UIS\to release\excel\sample6.mdb</FilesToBackup> <DestinationFolder>c:\Invoice Manager for Excel Backup\</DestinationFolder> <LogFile>c:\Invoice Manager for Excel Backup\backup-log.txt</LogFile> </cBackupOptionsData>
The options shown in the BackupSettings.xml match what shown on the Backup Scheduler dialog box inside Invoice Manager for Excel. It's pretty straightforward, except the <DaysOfWeek> element, which uses an integer number to identify which days of week to run the backup. This <DaysOfWeek> value is in fact a sum the following week day numbers:
So for example, if the task should be run on each Sunday and Monday, you fill 1 + 2 = 3 into the <DaysOfWeek> element.