public void RunAuthentication() { if (Login != null && Login == loadLogin) { MainMenuForm cinema = new MainMenuForm(Login, FullName, Position, lvlAccses); cinema.Show(); } else { MessageBox.Show("Аккаунт не зарегистрирован!", "Внимание!"); } }
public MainMenuForm(string login, string fullName, string position, int lvlAccses) { InitializeComponent(); Login = login; FullName = fullName; Positions = position; LvlAccses = lvlAccses; mainMenu = this; FillUserDate(); ProvidingAccses(); Application.OpenForms[0].Hide(); }