Beispiel #1
0
        private void btnConnect_Click(object sender, EventArgs e)
        {
            SelectServer frmOptions = (SelectServer)((Control)sender).Parent;

                String address = frmOptions.getSelectedServer();
                int port = frmOptions.getSelectedPort();

                Server srv = new Server(address, port);
                srv.Show();
                ((Form)frmOptions).Close();
        }