public class ReportScheduleInfoOnce : ReportScheduleInfo
An extension of the ReportScheduleInfo base class, a ReportScheduleInfoOnce object describes a schedule with no recurrence pattern.
public class ReportScheduleInfoOnce : ReportScheduleInfo
using NodaTime; ... // Run-once, immediately save to disk string jobId; // Use to retrieve schedule info later for editing int hostIdx; // Assigned execution host id ReportScheduleInfo newSchedule = new ReportScheduleInfoOnce() { ScheduleName = "Immediate Schedule", // Schedule name ReportType = wrReportType.Advanced, // Report type RangeStartDate = new LocalDate(DateTime.Now.Year, DateTime.Now.Month, DateTime.Now.Day), // Start date ScheduleTime = new LocalTime(DateTime.Now.Hour, DateTime.Now.Minute), // Start time SendReportInEmail = false // Email or save }; // Send to the scheduler; wrap in try/catch to handle exceptions try { api.ReportScheduler.AddReport( new ReportSchedule(api.PageInfo) { ScheduleInfo = newSchedule }, out jobId, out hostIdx); } catch (Exception) { }
System.Object
WebReports.Api.Scheduler.ReportScheduleInfo
WebReports.Api.Scheduler.ReportScheduleInfoOnce