[C#]WinForm全螢幕播放,把工作列和Mouse給Hidden小技巧

之前有網友問到這個問題,小弟一樣去找了資料..
只要幾行程就可以把工作列和mouse給hidden..

之前有網友問到這個問題,小弟一樣去找了資料..
只要幾行程就可以把工作列和mouse給hidden..
winform(c#)

        private void Form1_KeyUp(object sender, KeyEventArgs e)
        {
            if (e.KeyCode == Keys.F5)//按F5全螢幕(包含工作列和mouse給hidden)
            {
                this.FormBorderStyle = FormBorderStyle.None;
                this.WindowState = FormWindowState.Maximized;
                Cursor.Hide();
            }

            if (e.KeyCode == Keys.Escape)//按Esc還原狀態
            {
                this.WindowState = FormWindowState.Normal;
                this.FormBorderStyle = FormBorderStyle.Sizable;
                Cursor.Show();
            }

        }

參考網址:

http://www.blueshop.com.tw/board/show.asp?subcde=BRD200806241617119JQ&fumcde=FUM20050124192253INM#BRD20080624220441IB4