protected void mvConference_ActiveViewChanged(object sender, EventArgs e) { MultiView mv = (MultiView)sender; switch (mv.ActiveViewIndex) { case 0: //Start break; case 1: //Wait WaitScreen.IncidentId = incidentId; WaitScreen.Start(); break; case 2: //Connect LiveConnect.IncidentId = incidentId; LiveConnect.Start(); break; case 3: //Survey Survey.IncidentId = incidentId; Survey.Start(); break; case 4: //Error ErrorControl.Start(); break; default: break; } upPage.Update(); }
private static void Login(Action callback) { liveConnect = new LiveConnect( Properties.Resources.clientID, Properties.Resources.clientSecret, new string[] { "wl.offline_access", "office.onenote_update", "office.onenote_create" } ); liveConnect.SigniningOverlay = null; if (sessionExists()) { System.Diagnostics.Debug.WriteLine("Refresh token encountered\n" + getRefreshToken()); liveConnect.ResumeSession(getRefreshToken(), () => { onLoggedIn(callback); }); } else { System.Diagnostics.Debug.WriteLine("Refresh token not found"); liveConnect.ShowLoginDialog(() => { onLoggedIn(callback); }); } }
private static void Login(Action callback) { liveConnect = new LiveConnect( Properties.Resources.clientID, Properties.Resources.clientSecret, new string[] { "wl.offline_access", "office.onenote_update", "office.onenote_create" } ); liveConnect.SigniningOverlay = null; if (sessionExists()) { System.Diagnostics.Debug.WriteLine("Refresh token encountered\n" + getRefreshToken()); liveConnect.ResumeSession(getRefreshToken(), () => { onLoggedIn(callback); }); } else { System.Diagnostics.Debug.WriteLine("Refresh token not found"); liveConnect.ShowLoginDialog(() => { onLoggedIn(callback); }); } }