C#透屏幕,屏幕扩展
Posted 风雨丛中住着一只南飞的雁,
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了C#透屏幕,屏幕扩展相关的知识,希望对你有一定的参考价值。
1 if (!SCREEN_STATE) 2 { 3 if (System.Windows.Forms.Screen.AllScreens.Count() > 1) 4 { 5 System.Windows.Forms.Screen s2 = System.Windows.Forms.Screen.AllScreens[1]; 6 System.Drawing.Rectangle r2 = s2.WorkingArea; 7 bigScreen = new BigScreen(); 8 9 bigScreen.GridMainContent.Children.Clear(); 10 TeamDataPage s = new TeamDataPage(); 11 bigScreen.GridMainContent.Children.Add(s); 12 13 bigScreen.Top = r2.Top; 14 bigScreen.Left = r2.Left; 15 bigScreen.Width = r2.Width; 16 bigScreen.Height = r2.Height; 17 bigScreen.Show(); 18 bigScreen.WindowState = WindowState.Maximized; 19 btn_BigScreen.Content = " 停止显示 "; 20 SCREEN_STATE = true; 21 } 22 else 23 { 24 MessageBox.Show("找不到扩展屏幕!"); 25 } 26 } 27 else 28 { 29 btn_BigScreen.Content = " 大屏显示 "; 30 if (bigScreen != null) 31 bigScreen.Close(); 32 33 SCREEN_STATE = false; 34 }
1、根据屏幕宽度,将要透屏的内容显示在主屏幕宽度之外!
以上是关于C#透屏幕,屏幕扩展的主要内容,如果未能解决你的问题,请参考以下文章