public FaultReport GenerateFaultReport() { FaultReport result = null; if (!DashboardData.DashboardStateManager.DashboardStateContains(DashboardState.FaultReport)) { FaultReportControl faultReporter = null; Dispatcher.Invoke(new Action(() => { faultReporter = new FaultReportControl(DashboardData); DashboardData.FaultReportPrompt = faultReporter; })); faultReporter.PresentModal(); //DashboardData.DashboardState = DashboardState.Default; faultReporter.Reset(); result = faultReporter.FaultReport; Dispatcher.Invoke(new Action(() => DashboardData.FaultReportPrompt = null)); } return(result); }
public FaultReport GenerateFaultReport() { FaultReport result = null; if (!DashboardData.DashboardStateManager.DashboardStateContains(DashboardState.FaultReport)) { FaultReportControl faultReporter = null; Dispatcher.Invoke(new Action(() => { faultReporter = new FaultReportControl(DashboardData); DashboardData.FaultReportPrompt = faultReporter; })); faultReporter.PresentModal(); //DashboardData.DashboardState = DashboardState.Default; faultReporter.Reset(); result = faultReporter.FaultReport; Dispatcher.Invoke(new Action(() => DashboardData.FaultReportPrompt = null)); } return result; }