Home > Software engineering >  How to implement user switches?
How to implement user switches?

Time:10-27

 CMainFrame * pFrame=(CMainFrame *) AfxGetMainWnd ();//get the main interface pointer 

PFrame - & gt; ShowWindow (SW_HIDE);

//to pop up the login dialog
CDlg_login DLG.

If (IDOK==DLG. DoModal ())
PFrame - & gt; ShowWindow (SW_SHOW);

The else exit (0);

So just hide the main interface, log in again when I am on the main interface of user or the user before, is there any way to reload the main interface once, for the interface shows that in the main user interface of the OnInitialUpdate (); Implementation, in the main interface is the formview

CodePudding user response:

Think too much, and restart the program
  • Related