Moderators big_daddy Posted February 8, 2008 Moderators Share Posted February 8, 2008 There are several examples of enabling the quick launch toolbar via button clicks, but here's an example using a windows message. expandcollapse popup_QuickLaunch_SetState(False) Sleep(2500) _QuickLaunch_SetState(True) Sleep(2500) _QuickLaunch_SetState(False) Sleep(2500) _QuickLaunch_SetState(True) Exit ;=============================================================================== ; ; Function Name: _QuickLaunch_SetState ; Description: Enable/disable the quick launch toolbar ; Parameter(s): $fState - Specifies whether to enable or disable the quick launch toolbar. ; True (1) = toolbar is enabled ; False (0) = toolbar is disabled ; Requirement(s): Windows 2000 or XP ; Return Value(s): Success - Return value from _SendMessage ; Failure - @error is set ; @error - 1 = Invalid $fState, 2 = Unable to get handle for Shell_TrayWnd ; Author(s): Bob Anthony (big_daddy) ; ;=============================================================================== ; Func _QuickLaunch_SetState($fState) Const $WM_USER = 0X400 Const $WMTRAY_TOGGLEQL = ($WM_USER + 237) If $fState <> 0 And $fState <> 1 Then Return SetError(1, 0, 0) $hTrayWnd = WinGetHandle("[CLASS:Shell_TrayWnd]") If @error Then Return SetError(2, 0, 0) Return _SendMessage($hTrayWnd, $WMTRAY_TOGGLEQL, 0, $fState) EndFunc ;==>_QuickLaunch_SetState ; Author GaryFrost Func _SendMessage($hWnd, $iMsg, $wParam = 0, $lParam = 0, $iReturn = 0, $wParamType = "wparam", $lParamType = "lparam", $sReturnType = "lparam") Local $aResult = DllCall("user32.dll", $sReturnType, "SendMessage", "hwnd", $hWnd, "int", $iMsg, $wParamType, $wParam, $lParamType, $lParam) If @error Then Return SetError(@error, @extended, "") If $iReturn >= 0 And $iReturn <= 4 Then Return $aResult[$iReturn] Return $aResult EndFunc ;==>_SendMessage Link to comment Share on other sites More sharing options...
JRSmile Posted February 8, 2008 Share Posted February 8, 2008 does nothing on my win2k machine. $a=StringSplit("547275737420796F757220546563686E6F6C75737421","") For $b=1 To UBound($a)+(-1*-1*-1)step(2^4/8);&$b+=1*2/40*µ&Asc(4) Assign("c",Eval("c")&Chr(Dec($a[$b]&$a[$b+1])));''Chr("a")&"HI" Next ;time_U&r34d,ths,U-may=get$the&c.l.u.e;b3st-regards,JRSmile; MsgBox(0x000000,"",Eval("c"));PiEs:d0nt+*b3.s4d.4ft3r.1st-try:-) Link to comment Share on other sites More sharing options...
Zedna Posted February 8, 2008 Share Posted February 8, 2008 Looks really nice big_daddy!! Unfortunatelly it doesn't work on my WIN98 :-( Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
Moderators big_daddy Posted February 8, 2008 Author Moderators Share Posted February 8, 2008 does nothing on my win2k machine.What is the class for your toolbar window? Link to comment Share on other sites More sharing options...
Zedna Posted February 8, 2008 Share Posted February 8, 2008 What is the class for your toolbar window?CLASS:Shell_TrayWnd is OK on WIN98. Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now