void ApplicationOnSetupComplete(object sender, EventArgs eventArgs) { Application.SetupComplete -= ApplicationOnSetupComplete; if (!Enabled()) return; var stdSchedulerFactory = new XpandSchedulerFactory(Application); stdSchedulerFactory.Initialize(); _scheduler = stdSchedulerFactory.GetScheduler(); }
void ApplicationOnSetupComplete(object sender, EventArgs eventArgs) { Application.SetupComplete -= ApplicationOnSetupComplete; if (!Enabled()) return; var stdSchedulerFactory = new XpandSchedulerFactory(Application); stdSchedulerFactory.Initialize(); Retry.Do(() => { _scheduler = stdSchedulerFactory.GetScheduler(); }, TimeSpan.FromSeconds(10)); }