C# 控制程序输出在指定屏幕上

           //程序出现在哪个屏幕上
            var startScreen = 1;
            if (startScreen <= Screen.AllScreens.Length)
            {
                //下标减1
                startScreen = startScreen - 1;
                Location = new Point(Screen.AllScreens[startScreen].Bounds.X, Screen.AllScreens[startScreen].Bounds.Y);
            }
            else
            {
                MessageBox.Show($"未检测到屏幕{StartScreen}");
            }

  

posted on 2017-07-24 14:16  微风吹过12x  阅读(134)  评论(0编辑  收藏

导航