                 default:
                     return ""
                 }
-            } else {
-                if active {
-                    if tableColumn!.identifier.rawValue == "active" {
-                        return #imageLiteral(resourceName: "complete")
+            case "dateStart":
+                if object[tableColumn!.identifier] as? String == "01 Jan 1900 00:00" {
+                    return NSLocalizedString("no startdate", comment: "Schedule details")
+                } else {
+                    let stringdate: String = object[tableColumn!.identifier] as? String ?? ""
+                    if stringdate.isEmpty {
+                        return ""
                     } else {
-                        return object[tableColumn!.identifier] as? String
-                    }
+                        let date = dateformatter.date(from: stringdate)
+                        return date?.localizeDate()
+                    }
+                }
+            case "dateStop":
+                if object[tableColumn!.identifier] as? String == "01 Jan 2100 00:00" {
+                    return "no stopdate"
                 } else {
-                    if tableColumn!.identifier.rawValue == "dateStart" {
-                        if object[tableColumn!.identifier] as? String == "01 Jan 1900 00:00" {
-                            return NSLocalizedString("no startdate", comment: "Schedule details")
-                        } else {
-                            let stringdate: String = object[tableColumn!.identifier] as? String ?? ""
-                            if stringdate.isEmpty {
-                                return ""
-                            } else {
-                                let date = dateformatter.date(from: stringdate)
-                                return date?.localizeDate()
-                            }
-                        }
-                    } else if tableColumn!.identifier.rawValue == NSLocalizedString("dateStop", comment: "Schedule details") {
-                        if object[tableColumn!.identifier] as? String == "01 Jan 2100 00:00" {
-                            return "no stopdate"
-                        } else {
-                            let stringdate: String = object[tableColumn!.identifier] as? String ?? ""
-                            if stringdate.isEmpty {
-                                return ""
-                            } else {
-                                let date = dateformatter.date(from: stringdate)
-                                return date?.localizeDate()
-                            }
-                        }
+                    let stringdate: String = object[tableColumn!.identifier] as? String ?? ""
+                    if stringdate.isEmpty {
+                        return ""
                     } else {
-                        return object[tableColumn!.identifier] as? String
-                    }
-                }
-            }
-        }
-        return nil
-        }
+                        let date = dateformatter.date(from: stringdate)
+                        return date?.localizeDate()
+                    }
+                }
+            case "numberoflogs":
+                return object[tableColumn!.identifier] as? String
+            default:
+                return nil
+            }
+        } else {
+            return nil
+        }
+        }
+    return nil
     }
 
     func tableView(_ tableView: NSTableView, setObjectValue object: Any?, for tableColumn: NSTableColumn?, row: Int) {

extension ViewControllerSchedule: NSTableViewDelegate, Attributedestring {

   func tableView(_ tableView: NSTableView, objectValueFor tableColumn: NSTableColumn?, row: Int) -> Any? {
    if tableView == self.scheduletable {
        guard row < self.configurations!.getConfigurationsDataSourceSynchronize()!.count else { return nil }
            let object: NSDictionary = self.configurations!.getConfigurationsDataSourceSynchronize()![row]
            let hiddenID: Int = object.value(forKey: "hiddenID") as? Int ?? -1
            switch tableColumn!.identifier.rawValue {
            case "scheduleID" :
                if self.schedulessorted != nil {
                    let schedule: String? = self.schedulessorted!.sortandcountscheduledonetask(hiddenID, profilename: nil, number: false)
                    if schedule?.isEmpty == false {
                        switch schedule {
                        case "once":
                            return NSLocalizedString("once", comment: "main")
                        case "daily":
                            return NSLocalizedString("daily", comment: "main")
                        case "weekly":
                            return NSLocalizedString("weekly", comment: "main")
                        case "manuel":
                            return NSLocalizedString("manuel", comment: "main")
                        default:
                            return ""
                        }
                    } else {
                        return ""
                    }
                }
            case "offsiteServerCellID":
                if (object[tableColumn!.identifier] as? String)!.isEmpty {
                    if self.index() ?? -1 == row && self.index == nil {
                        return self.attributedstring(str: "localhost", color: NSColor.red, align: .left)
                    } else {
                        return "localhost"
                    }
                } else {
                    if self.index() ?? -1 == row && self.index == nil {
                        let text = object[tableColumn!.identifier] as? String
                        return self.attributedstring(str: text!, color: NSColor.red, align: .left)

                    active = false
                }
            }
            switch tableColumn!.identifier.rawValue {
            case "stopCellID", "deleteCellID":
                return object[tableColumn!.identifier] as? Int
            case "schedule":
                switch object[tableColumn!.identifier] as? String {
                case "once":
                    return NSLocalizedString("once", comment: "main")
