How to make full screen mode, without covering the taskbar using :wpf c#

前端 未结 6 1364
谎友^
谎友^ 2020-12-17 17:44

I need to change windows taskbar in my WPF application. For that I set WindowStyle=\"None\", which means to disable the windows taskbar, and make custom taskbar

6条回答
  •  感动是毒
    2020-12-17 18:11

    Found a solution on CodeProject which may help: http://www.codeproject.com/Articles/107994/Taskbar-with-Window-Maximized-and-WindowState-to-N

    WindowStyle="None"
    WindowState="Maximized"
    ResizeMode="NoResize"
    

    and

    this.Width = System.Windows.Forms.Screen.PrimaryScreen.WorkingArea.Width;
    this.Height = System.Windows.Forms.Screen.PrimaryScreen.WorkingArea.Height;
    this.Left = 0;
    this.Top = 0;
    this.WindowState = WindowState.Normal;
    

提交回复
热议问题