Maximized screen ignores taskbar

前端 未结 8 1747
刺人心
刺人心 2020-12-20 16:53

I have a form I set to Maximized, but for some reason it\'s ignoring the taskbar and maximizing to the entire screen. Is that typical? Is there a workaround?

8条回答
  •  长情又很酷
    2020-12-20 17:03

    One thing I left out of the description--I'd turned off the maximize button. When I tested turning that property back on, the task bar showed up again. Apparently it assumes if you don't want a maximize button you are creating a kiosk-style application where you don't want your users to see anything but the application screen. Not exactly what I'd expect, but works I guess.

    I had this problem and solved it by Jeff's help. First, set the windowstate to Maximized. but Do not disable the MaximizeBox. Then if you want MaximizeBox to be disabled you should do it programmatically:

    private void frmMain_Load(object sender, EventArgs e)
    {
       this.MaximizeBox = false;
    }
    

提交回复
热议问题