Outbreaker Posted September 22, 2008 Share Posted September 22, 2008 (edited) I use this script to enable the "Quick Launch" but i can't find any command for enabling "Auto-hide the taskbar" #Include <SendMessage.au3> Const $WM_USER = 0X400 Const $WMTRAY_TOGGLEQL = ($WM_USER + 237) If $CmdLine[0] = 1 Then Select Case $CmdLine[1] = 0 _SendMessage(WinGetHandle("[CLASS:Shell_TrayWnd]"), $WMTRAY_TOGGLEQL, 0, False) Case $CmdLine[1] = 1 _SendMessage(WinGetHandle("[CLASS:Shell_TrayWnd]"), $WMTRAY_TOGGLEQL, 0, True) EndSelect EndIf Edited September 22, 2008 by Outbreaker Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted September 22, 2008 Moderators Share Posted September 22, 2008 ControlHide Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
Outbreaker Posted September 22, 2008 Author Share Posted September 22, 2008 No that's not working. TOGGLEQL = Ouick Launch I am searching for the hide taskbar. Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted September 22, 2008 Moderators Share Posted September 22, 2008 (edited) No that's not working. TOGGLEQL = Ouick LaunchI am searching for the hide taskbar.Yes that is working. You're just not using it right Use the ClassNameNN of the TaskBar. It's been done a ton of times on here in fact.Edit:I may have totally mistaken what you're asking though >_< ... not unusual.I think you want to just enable, not progmatically do it from your script Edited September 22, 2008 by SmOke_N Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
AdmiralAlkex Posted September 22, 2008 Share Posted September 22, 2008 @SmOke_N Afaik he wants to turn it permanently off which seems to be a bit tricky, using the registry is hard and using ControlCommand() is not very "clean". There should be a proper solution but I don't know it .Some of my scripts: ShiftER, Codec-Control, Resolution switcher for HTC ShiftSome of my UDFs: SDL UDF, SetDefaultDllDirectories, Converting GDI+ Bitmap/Image to SDL Surface Link to comment Share on other sites More sharing options...
Outbreaker Posted September 22, 2008 Author Share Posted September 22, 2008 (edited) I have an other script that i snipped together but the problem is that it's only working on English Windows. And i don't now how to make it language-independent. I think its works with the "WinGetHandle" command but i am little bit lost how make the script work with that. I tryd but failed. If $CmdLine[0] = 1 Then Select Case $CmdLine[1] = 0 Run("Rundll32.exe SHELL32.DLL,Options_RunDLL 1") WinWaitActive("Taskbar and Start Menu Properties", "Taskbar", 6) ControlFocus("Taskbar and Start Menu Properties", "Taskbar","SysTabControl321") If ControlCommand("Taskbar and Start Menu Properties", "Taskbar", "Button5", "IsChecked") = 1 Then ControlCommand("Taskbar and Start Menu Properties", "Taskbar", "Button5", "UnCheck") ControlClick("Taskbar and Start Menu Properties", "Taskbar", "Button11") Else WinClose("Taskbar and Start Menu Properties") EndIf Case $CmdLine[1] = 1 Run("Rundll32.exe SHELL32.DLL,Options_RunDLL 1") WinWaitActive("Taskbar and Start Menu Properties", "Taskbar", 6) ControlFocus("Taskbar and Start Menu Properties", "Taskbar","SysTabControl321") If ControlCommand("Taskbar and Start Menu Properties", "Taskbar", "Button5", "IsChecked") = 1 Then WinClose ("Taskbar and Start Menu Properties") Else ControlCommand("Taskbar and Start Menu Properties", "Taskbar", "Button5", "Check") ControlClick("Taskbar and Start Menu Properties", "Taskbar", "Button11") EndIf EndSelect EndIf Edited September 22, 2008 by Outbreaker Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted September 23, 2008 Moderators Share Posted September 23, 2008 (edited) This is the best I could do before Heros started ...I'm not happy with having to kill explorer, there's a CE dll call to refresh I tried, but it failed (I even though to just put up a gui of the current screen and lock the mouse >_< ). Maybe someone else can pick it up.The descriptions of what can be done are in the function:expandcollapse popup_TaskBar_SetState(2) Func _TaskBar_SetState($i_set = 2) #cs 1 = Auto Hide and Show Clock 2 = Always on Top and Show Clock 3 = Always on Top and Auto Hide and Show Clock 4 = Show small icons in Start Menu and Show Clock 5 = Always on Top and Show small icons in Start Menu 6 = Always on Top and Auto Hide and Show small icons in Start Menu 7 = Always on Top and Show small icons in Start Menu and Show Clock 8 = All Options Enabled 9 = Always on Top and Auto Hide 10 = Auto Hide and Show small icons in Start Menu #ce Local Const $WM__SETTINGCHANGE = 0x001A Local $s_set_num Switch Int($i_set) Case 1, 2, 3, 4 $s_set_num = StringFormat("%02s", Int($i_set)) Case 5 $s_set_num = "0E" Case 6 $s_set_num = "0F" Case 7 $s_set_num = "06" Case 8 $s_set_num = "07" Case 9 $s_set_num = "0B" Case 10 $s_set_num = "0D" Case Else Return SetError(1, 0, 0) EndSwitch Local $s_key = "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\StuckRects2" If @OSType = "WIN32_WINDOWS" Then $s_key = "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\StuckRects" Local $s_current_val = RegRead($s_key, "Settings") Local $s_compare = StringRegExpReplace($s_current_val, "(.{16})(.{2})(.+?)\z", "\2") If $s_compare = $s_set_num Then Return $s_current_val Local $s_convert = StringReplace(StringRegExpReplace($s_current_val, "(.{16})(.{2})(.+?)\z", "\1 " & $s_set_num & " \3"), " ", "") RegWrite($s_key, "Settings", "REG_BINARY", $s_convert) ; CE method doesn't work , can't figure out the right values that are used. ;DllCall("User32.dll", "int", "SendMessage", "hwnd", WinGetHandle("[CLASS:Shell_TrayWnd]"), "int", $WM__SETTINGCHANGE, "wparam", 0, "lparam", 5000) Local $i_explorer_pid = ProcessExists("explorer.exe") ProcessClose($i_explorer_pid) ProcessWait("explorer.exe") Return $s_current_val EndFuncEdit:http://msdn.microsoft.com/en-us/library/ms725497(VS.85).aspxOops, guess I forgot to work with SystemParametersInfo() http://msdn.microsoft.com/en-us/library/ms724947(VS.85).aspxIn my DllCall method I originally tried.If ya'll figure it before I'm interested again, feel free. Edited September 23, 2008 by SmOke_N Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. 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