Click or drag to resize

ControllerRestore Method

This method starts restoring a backup.

Namespace:  ABB.Robotics.Controllers
Assembly:  ABB.Robotics.Controllers (in ABB.Robotics.Controllers.dll) Version: 6.5.129.0
Syntax
C#
public void Restore(
	string dirPath,
	RestoreInclude include,
	RestoreIgnore ignore
)

Parameters

dirPath
Type: SystemString
Path to where the backup to restore is saved.
include
Type: ABB.Robotics.ControllersRestoreInclude
A filter that determines what to restore(See flags RestoreInclude).
ignore
Type: ABB.Robotics.ControllersRestoreIgnore
A filter that determines what kind of differences to accept (See flags RestoreIgnore).
Exceptions
ExceptionCondition
GeneralExceptionA General Exception has occurred.
Remarks
If the method is successful, the controller performs a restart, else an exception is thrown. The backup directory must be on the controller file system. The user must have the grant for the restore operation and mastership for the resources Cfg and Rapid.
Examples
This example restores a backup from a known location. In this example a controller object 'c' is already created and the event comes from a button click. The backupDir is set by the user.
private void restore_Click(object sender, System.EventArgs e)
{
    try
    {
        c.Restore(backupDir,RestoreInclude.All, RestoreIgnore.All);
    }
    catch(GeneralException ex)
    {
        // handle error from restore
    }
    catch(System.Exception ex)
    {
        //Handle error
    }    
}
See Also