コード例 #1
0
        private void Form1_Load(object sender, EventArgs e)
        {
            SplashBaseComs coms = new SplashBaseComs();

            cmbColourMode.SelectedIndex = 0;
            coms.Ping(IPAddress.Parse(textBox1.Text));
        }
コード例 #2
0
        private void button3_Click_1(object sender, EventArgs e)
        {
            SplashBaseComs coms = new SplashBaseComs();

            coms.Ping(IPAddress.Parse(textBox1.Text));

            //coms.BroadcastPing();

            //byte[] data = new byte[6];
            //IPEndPoint ipep = new IPEndPoint(IPAddress.Broadcast, 11028);
            //UdpClient BcastClient = new UdpClient(AddressFamily.InterNetwork);

            //data[0] = 1;
            //data[1] = Convert.ToByte('H');
            //data[2] = Convert.ToByte('e');
            //data[3] = Convert.ToByte('l');
            //data[4] = Convert.ToByte('l');
            //data[5] = Convert.ToByte('o');

            //BcastClient.EnableBroadcast = true;
            //BcastClient.Send(data, data.Length, ipep);
        }