Run in full screen with no start menu [duplicate]

人盡茶涼 提交于 2019-12-24 00:54:06

问题


Possible Duplicate:
Making Winforms Fullscreen

I am making a VB Form that i want to run in full screen, as in covering the start menu and task bar. right now i am using

    Me.Size = SystemInformation.PrimaryMonitorSize
    Me.WindowState = 2
    Me.Location = New Point(0, 0)
    Me.TopMost = True
    Me.FormBorderStyle = 0

but the start menu still shows. I am assuming this is because the window is just maximized and not really in "full screen"

is there any way i can cover the start menu in vb to make the program run in full screen?


回答1:


There appear to be some side-effects going on here. If you just reorder the lines, it should work fine. In fact, setting the WindowState to maximized or enabling "always on top" do not appear to be explicitly required to achieve this effect.

Me.FormBorderStyle = Windows.Forms.FormBorderStyle.None
Me.Location = New Point(0, 0)
Me.Size = SystemInformation.PrimaryMonitorSize
'Me.WindowState = 2
'Me.TopMost = True


来源:https://stackoverflow.com/questions/14554186/run-in-full-screen-with-no-start-menu

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!