Assign a boolean variable maximized. If maximized is true and the button gets pressed, restore to normal size. If not and the button is pressed, maximize the form.
"does any one know how to hide the taskbar along with the taskbar????"
What?
hello i am making a web browser and i am givving a button this functionwhich will work as full screen modeCode:FormBorderStyle = Windows.Forms.FormBorderStyle.None WindowState = FormWindowState.Maximized
how do i make it so if i click the button again it restore it to its normal sizeCode:FormBorderStyle = Windows.Forms.FormBorderStyle.Sizable WindowState = FormWindowState.Normal
also
does any one know how to hide the taskbar along with the taskbar????
Last edited by hopefordope; 06-03-2010 at 11:21 AM.
Press Thank You[IMG]https://i45.tinypic.com/2hg8w0n.jpghttps://img1.UploadScreensho*****m/images/main/2/3203234450.jpg[/IMG]
My Releases
Injector 3G
Injector 2G
Injector 1G
Super Spammer
CA Cleaner
My Tutorials
How to Make a real Injector(PerX)
How to Make a Calculator(leeched)
Assign a boolean variable maximized. If maximized is true and the button gets pressed, restore to normal size. If not and the button is pressed, maximize the form.
"does any one know how to hide the taskbar along with the taskbar????"
What?
Assembly Programmer
You need to toggle the window state by using the IF statement. Here's how you can do it:
For hiding your program from the taskbar, use the following command:Code:If Me.WindowState = FormWindowState.Maximized Then Me.WindowState = FormWindowState.Normal Else Me.WindowState = FormWindowState.Maximized End If
Where me is your current form. You can change it with whatever Form you like. To show the form in the taskbar, simply set the value to True.Code:Me.ShowInTaskbar = False
Hope this helps
thanks you flame the first part worked flawlessly but for the second one i meant to say that how do i hide the taskbar not my icon in the taskbar but the taskbar itself
Press Thank You[IMG]https://i45.tinypic.com/2hg8w0n.jpghttps://img1.UploadScreensho*****m/images/main/2/3203234450.jpg[/IMG]
My Releases
Injector 3G
Injector 2G
Injector 1G
Super Spammer
CA Cleaner
My Tutorials
How to Make a real Injector(PerX)
How to Make a Calculator(leeched)
So you mean literally remove the taskbar?
yeah but it temporarily hides and it can be restored
Press Thank You[IMG]https://i45.tinypic.com/2hg8w0n.jpghttps://img1.UploadScreensho*****m/images/main/2/3203234450.jpg[/IMG]
My Releases
Injector 3G
Injector 2G
Injector 1G
Super Spammer
CA Cleaner
My Tutorials
How to Make a real Injector(PerX)
How to Make a Calculator(leeched)
Hmm.. I once did a side bar application in which I hide the task bar. Following is the code for the hiding, but unfortunately it works on XP and Vista only. Right now I've 7 installed so, I can't check it. Anyways, here's the MSDN standard API calls to hide and show the task bar:
■ First add these declarations:
Private Declare Function SetWindowPos Lib "user32"( ByVal hwnd As Long , ByVal hWndInsertAfter As Long , ByVal x As Long , ByVal y As Long , ByVal cx As Long , ByVal cy As Long , ByVal wFlags As Long ) As Long
Private Declare Function FindWindow Lib "user32" Alias "FindWindowA"( ByVal lpClassName As String , ByVal lpWindowName As String ) As Long
Const SWPHIDEWINDOW = & H80
Const SWPSHOWWINDOW = & H40
Dim TaskBarHwnd As Long
■ Then on Form's Load event, add the following line:
TaskBarHwnd = FindWindow( "Shell_traywnd", "")
■ Then add the following sub-procedures that call show and hide the task bar:
Sub HideTaskbar()
Call SetWindowPos(TaskBarHwnd,0 & ,0 & ,0 & ,0 & ,0 & ,SWPHIDEWINDOW)
End Sub
Sub ShowTaskbar()
Call SetWindowPos(TaskBarHwnd,0 & ,0 & ,0 & ,0 & ,0 & ,SWPSHOWWINDOW)
End Sub
■ Finally, call these subs as required !!!
Hope this helps !!