VB icon

Disable the Windows Taskbar

Email
Submitted on: 1/1/2015 7:38:00 AM
By: StonePage (from psc cd)  
Level: Not Given
User Rating: By 3 Users
Compatibility: VB 4.0 (32-bit), VB 5.0, VB 6.0
Views: 818
 
     Disable the Taskbar
 

Windows API/Global Declarations:

Can't Copy and Paste this?
Click here for a copy-and-paste friendly version of this code!
'**************************************
'Windows API/Global Declarations for :Disable the Windows Taskbar
'**************************************
Dim hwnd1 As Long
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 SWP_HIDEWINDOW &H80
Const SWP_SHOWWINDOW &H40
code:
Can't Copy and Paste this?
Click here for a copy-and-paste friendly version of this code!
				
'**************************************
' Name: Disable the Windows Taskbar
' Description:Disable the Taskbar
' By: StonePage (from psc cd)
'**************************************

3. Add a Command Button control to Form1. Command1 is created by
default. Set its Caption property to "Hide".
4. Add the following code to the Click event for Command1.
Private Sub Command1_Click()
hwnd1 = FindWindow("Shell_traywnd", "")
Call SetWindowPos(hwnd1, 0, 0, 0, 0, 0, SWP_HIDEWINDOW)
End Sub
5. Add a second Command Button control to Form1. Command2 is created by 
default. Set its Caption property to "Show".
6. Add the following code to the Click event for Command2.
Private Sub Command2_Click()
Call SetWindowPos(hwnd1, 0, 0, 0, 0, 0, SWP_SHOWWINDOW)
End Sub


Other 1 submission(s) by this author

 


Report Bad Submission
Use this form to tell us if this entry should be deleted (i.e contains no code, is a virus, etc.).
This submission should be removed because:

Your Vote

What do you think of this code (in the Not Given category)?
(The code with your highest vote will win this month's coding contest!)
Excellent  Good  Average  Below Average  Poor (See voting log ...)
 

Other User Comments


 There are no comments on this submission.
 

Add Your Feedback
Your feedback will be posted below and an email sent to the author. Please remember that the author was kind enough to share this with you, so any criticisms must be stated politely, or they will be deleted. (For feedback not related to this particular code, please click here instead.)
 

To post feedback, first please login.