-
I need to hide all of the controls on my form, turn it completely black, and cover the whole screen with it. (Black out the screen).
I have this:
Dim Control As Control
For Each Control In frmMain.Controls
Control.Visible = False
Next Control
Me.BackColor = vbBlack
Me.Move 0, 0, Screen.Width, Screen.Height
This does all that I want, but it does not cover the screen and the titlebar is still there. I tried:
Me.BorderStyle = 0
And:
Me.Caption = ""
Me.ControlBox = False
but VB won't let me do that.
Creating form that is completely black isn't really an option I'd like to consider - there is code in the KeyDown Event and Private Global Variables that need to stay with the form and a second form would just mess everthing up.
Any ideas?
-
Don't try to set all the properties at runtime. If you do it all at design time, it should work. What kind of program are you making?
-
Did you try Borderstyle=0 WindowState=2maximized to cover the whole screen and hide titlebar?
-
in the Project Properties menu at the left you can set the Border to 0 - None instead of anything else. As for maximizing im not sure.
-
Generally we tend to not answer three year old questions.
;)
-
meh...i got bored and started parusing