Jump to content

Any idea why this isn't working?


Recommended Posts

#Include <GuiToolBar.au3>

Func _TaskbarHideButton($sText, $bHide = True)
    $hToolbar = _GUICtrlToolbar_FindToolbar("[CLASS:Shell_TrayWnd]", $sText)
    If $hToolbar = 0 Then Return False
    For $i = 0 To _GUICtrlToolbar_ButtonCount($hToolbar)-1
        $cId = _GUICtrlToolbar_IndexToCommand($hToolbar, $i)
        If _GUICtrlToolbar_GetButtonText($hToolbar, $cId) = $sText Then
            Return _GUICtrlToolbar_HideButton($hToolbar, $cId, $bHide)
        EndIf
    Next
    Return False
EndFunc

It does nothing when it is called upon by _TaskbarHideButton('WindowName')... I had it working, but lost all my Includes when I reformatted :D

Thanks in advance.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...