コード例 #1
0
        private void VncClient_DataArrived(object sender, DataArrivedEventArgs e)
        {
            var message = VncClient.GetMessage(sender, e);

            if (message.StartsWith(VncCommand.ScreenSize))
            {
                var data   = message.Split(VncCommand.Separator, 'x');
                var width  = Convert.ToInt32(data[1]);
                var height = Convert.ToInt32(data[2]);

                cb_Computer.Invoke((MethodInvoker) delegate
                {
                    var mcf = new MouseControlForm(cb_Computer.Text, width, height);
                    mcf.Show();
                });
            }
        }