用户登录  |  用户注册
首 页商业源码原创产品编程论坛
当前位置:PB创新网文章中心编程技巧VisualBasic

VB源代码推荐: 动态的显示/隐藏start按钮

减小字体 增大字体 作者:佚名  来源:本站整理  发布时间:2009-03-16 19:47:14

VB源代码推荐 : 动态的显示/隐藏start按钮

' #VBIDEUtils#**********************************************
' * Programmer Name  : Waty Thierry
' * Web Site         : www.geocities.com/ResearchTriangle/6311/
' * E-Mail           : waty.thierry@usa.net
' * Date             : 22/10/98
' * Time             : 15:50
' * Module Name      : Start_Module
' * Module Filename  : Start.bas
' *********************************************************
' * Comments         : Show/Hide the start button
' *
' ********************************************************
Private Declare Function FindWindow Lib "user32" Alias _
   "FindWindowA" (ByVal lpClassName As String, _
   ByVal lpWindowName As String) As Long
   
Private Declare Function FindWindowEx Lib "user32" Alias _
   "FindWindowExA" (ByVal hWnd1 As Long, ByVal hWnd2 As Long, _
   ByVal lpsz1 As String, ByVal lpsz2 As String) As Long

Private Declare Function ShowWindow Lib "user32" _
    (ByVal hwnd As Long, ByVal nCmdShow As Long) As Long

Public Function hideStartButton()
   'This Function Hides the Start Button'
   OurParent& = FindWindow("Shell_TrayWnd", "")
   OurHandle& = FindWindowEx(OurParent&, 0, "Button",  _
       vbNullString)
   ShowWindow OurHandle&, 0
End Function

Public Function showStartButton()
   'This Function Shows the Start Button'
   OurParent& = FindWindow("Shell_TrayWnd", "")
   OurHandle& = FindWindowEx(OurParent&, 0, "Button", _
        vbNullString)

   ShowWindow OurHandle&, 5
End Function


Tags:

作者:佚名

文章评论评论内容只代表网友观点,与本站立场无关!

   评论摘要(共 0 条,得分 0 分,平均 0 分) 查看完整评论
PB创新网ourmis.com】Copyright © 2000-2009 . All Rights Reserved .
页面执行时间:18,250.00000 毫秒
Email:ourmis@126.com QQ:2322888 蜀ICP备05006790号