Exemple #1
0
        //Internet inter = new Internet();

        private void timer1_Tick(object sender, EventArgs e)
        {
            Internet intern = new Internet();
            bool     active = intern.isConnected;

            if (active == false)
            {
                timer1.Stop();
                MessageBox.Show("Not connected to internet.");
                Application.Exit();
            }
            Console.WriteLine(active);
        }
        private void timer1_Tick(object sender, EventArgs e)
        {
            bool active = ad.isClientActive(clientin.ClientKey);

            if (active == false)
            {
                timer1.Stop();
                MessageBox.Show("This client server is no longer active.");
                Application.Exit();
            }
            Internet intern   = new Internet();
            bool     activein = intern.isConnected;

            if (activein == false)
            {
                timer1.Stop();
                MessageBox.Show("Not connected to internet.");
                Application.Exit();
            }
        }