         if answer {
             if let index = self.index(viewcontroller: .vctabmain) {
                 self.restorebutton.isEnabled = false
+                self.abortandclose = true
                 self.initiateProgressbar()
                 self.outputprocess = OutputProcess()
                 self.sendprocess?.sendoutputprocessreference(outputprocess: self.outputprocess)

    var restorecompleted: Bool = false
    weak var sendprocess: SendProcessreference?
    var diddissappear: Bool = false

    // Close and dismiss view
    @IBAction func close(_ sender: NSButton) {
        if self.estimationcompleted == true && self.restorecompleted == false { self.abort() }
        self.dismissview(viewcontroller: self, vcontroller: .vctabmain)
    }

    @IBAction func dotmprestore(_ sender: NSButton) {
        guard self.tmprestore.stringValue.isEmpty == false else { return }
        self.restorebutton.isEnabled = false
        if let index = self.index(viewcontroller: .vctabmain) {
            self.selecttmptorestore.isEnabled = false
            self.estimationcompleted = false


extension ViewControllerRestore: UpdateProgress {
    func processTermination() {
        self.abortandclose = false
        if self.estimationcompleted == false {
            self.estimationcompleted = true
            self.setNumbers(outputprocess: self.outputprocess)
