Ejemplo n.º 1
0
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            MainContainer form = MainContainer.GetInstance();

            MainContainer.LoadForm(new LoginForm());
            Application.Run(form);
        }
Ejemplo n.º 2
0
 public static void LoadForm(Form form)
 {
     form.TopLevel = false;
     _instance     = MainContainer.GetInstance();
     MainContainer._instance.mainPanel.Controls.Add(form);
     form.FormBorderStyle = FormBorderStyle.None;
     form.Dock            = DockStyle.Fill;
     if (!form.Visible)
     {
         form.Show();
         form.BringToFront();
     }
     else
     {
         form.BringToFront();
     }
 }