0
I have a main menu form, which calls the student register.
But the exit code of the student form does not close it, calls the main form but it remains open in the background and I can’t even close it manually.
Code to open the registration menu:
frmCadAluno oloko = new frmCadAluno();
this.Visible = false;
oloko.ShowDialog();
Code to close:
FrmMenuPrincipal oloko = new FrmMenuPrincipal();
oloko.ShowDialog();
this.Close();
this.Dispose();
"code to open", which source form? is the main menu? In the "close code", try closing the current form before opening the main menu
– LeoHenrique
Misplaced question. Improve it there.
– Augusto Vasques
@Augustovasques
– LipESprY
You are opening the oloko and closing this, which would be the form that opened the oloko, try oloko. Close()
– Pablo Tondolo de Vargas
@Augustovasques I apologize, first time using stackoverflow. My mistake was in showdialog, it should be just show().
– Bruno Moraes
@Brunomoraes https://answall.com/help/asking
– Augusto Vasques