public ActionResult RunSchedule(ScheduleDto scheduleDto)
        {
            ActionResult ActionResult = new ActionResult();
            string       Data         = SchedulerFactory.Run_Schedule(scheduleDto);

            if (Data == "Success")
            {
                ActionResult.Message = Localization.GetString("RunNow", Components.Constants.TaskSchedulerResourcesFile);
            }
            else
            {
                ActionResult.AddError("RunNowError", Localization.GetString("RunNowError", Components.Constants.TaskSchedulerResourcesFile));
            }

            return(ActionResult);
        }
        public ActionResult DirectRunSchedule(int ScheduleID)
        {
            ActionResult ActionResult = new ActionResult();
            //ScheduleDto scheduleDto = GetSchedule_Item(ScheduleID).Data as ScheduleDto;
            dynamic     m           = SchedulerManager.GetSchedule_Item(ScheduleID).Data;
            ScheduleDto scheduleDto = new ScheduleDto
            {
                ScheduleID                = m.ScheduleID,
                TypeFullName              = m.TypeFullName,
                FriendlyName              = m.FriendlyName,
                TimeLapse                 = m.TimeLapse,
                TimeLapseMeasurement      = m.TimeLapseMeasurement,
                RetryTimeLapse            = m.RetryTimeLapse,
                RetryTimeLapseMeasurement = m.RetryTimeLapseMeasurement,
                RetainHistoryNum          = m.RetainHistoryNum,
                AttachToEvent             = m.AttachToEvent,
                CatchUpEnabled            = m.CatchUpEnabled,
                Enabled            = m.Enabled,
                ObjectDependencies = m.ObjectDependencies,
                ScheduleStartDate  = m.ScheduleStartDate,
                Servers            = m.Servers
            };

            string Data = SchedulerFactory.Run_Schedule(scheduleDto);

            if (Data == "Success")
            {
                ActionResult.Message = Localization.GetString("RunNow", Components.Constants.TaskSchedulerResourcesFile);
            }
            else
            {
                ActionResult.AddError("RunNowError", Localization.GetString("RunNowError", Components.Constants.TaskSchedulerResourcesFile));
            }

            return(ActionResult);
        }