Cha0sBG Posted August 20, 2008 Share Posted August 20, 2008 Hey i was wondering is there any way to disable the Minimize button Maximize button By disable i mean just remove them from there ^^ Have Questions About GUI (Graphical User Interface) ? Post Them Here :GUI Help And Support ForumHave Questions About General AutoIt ? Post Them Here : General Help And Support ForumNew To AutoIt ? Be Shure To Check Out The FaQ's (Frequently Asked Questions) Or FaQ ยน There You May Find Great Help That Will Guide You True The Wonderful Programming Language AutoItOthere Good Place To Get Some Knolage Of AutoIt Is The Example Script ForumNotice A Bug ? Please Go And Report it At Bug Report Section And Help The Devolepers Of AutoIt Update And Fix The Programming LanguageWant To Thank The People For This Great Forum And Programming Language ? Then DonateWhen You Found The Answer Your Looking For Please Add [Resolved] To The Thread's Name That Will Show Otheres That You Have Found What Your Looking For And They Whount Have To Enter The Thread. Link to comment Share on other sites More sharing options...
AdmiralAlkex Posted August 20, 2008 Share Posted August 20, 2008 Helpfile dude, learn to read the helpfile! #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> GUICreate("My GUI", -1, -1, -1, -1, BitOR($WS_CAPTION, $WS_SYSMENU)) GUISetState() While 1 $msg = GUIGetMsg() If $msg = $GUI_EVENT_CLOSE Then ExitLoop WEnd .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...
Moderators SmOke_N Posted August 20, 2008 Moderators Share Posted August 20, 2008 Helpfile dude, learn to read the helpfile! #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> GUICreate("My GUI", -1, -1, -1, -1, BitOR($WS_CAPTION, $WS_SYSMENU)) GUISetState() While 1 $msg = GUIGetMsg() If $msg = $GUI_EVENT_CLOSE Then ExitLoop WEndI think he's looking more for something like:expandcollapse popup#include <winapi.au3> $h_gui = GUICreate("my gui") GUISetState() $n_timer = TimerInit() While GUIGetMsg() <> -3 If $n_timer > 0 And TimerDiff($n_timer) / 1000 >= 3 Then _WinRemoveMinMaxBox($h_gui) $n_timer = 0 EndIf WEnd Func _WinRemoveMinMaxBox($h_wnd) Local Const $GWL__STYLE = -16 Local Const $WS__MAXIMIZEBOX = 0x0010000 Local Const $WS__MINIMIZEBOX = 0x0020000 If IsString($h_wnd) Then $h_wnd = WinGetHandle($h_wnd) Local $a_old_style = DllCall("user32.dll", "int", "GetWindowLong", "hwnd", $h_wnd, "int", $GWL__STYLE) If @error Then Return SetError(1, 0, 0) Local $i_style = 0 If BitAND($a_old_style[0], $WS__MAXIMIZEBOX) Then $i_style = BitOR($i_style, $WS__MAXIMIZEBOX) If BitAND($a_old_style[0], $WS__MINIMIZEBOX) Then $i_style = BitOR($i_style, $WS__MINIMIZEBOX) If Not $i_style Then Return $a_old_style[0] Local $a_set_window = DllCall("user32.dll", "int", "SetWindowLong", "hwnd", $h_wnd, "int", $GWL__STYLE, "long", $a_old_style[0] - $i_style) If @error Then Return SetError(2, 0, 0) ; Cheap way to refresh the title bar WinSetTitle($h_wnd, "", WinGetTitle($h_wnd)) Return $a_set_window[0] EndFuncBeing able to control it after the GUI is already made. 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 August 20, 2008 Share Posted August 20, 2008 I think he's looking more for something like:-snipped-Being able to control it after the GUI is already made.It could be, but it's impossible to tell until Cha0sBG learns to be more precise .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...
Moderators SmOke_N Posted August 20, 2008 Moderators Share Posted August 20, 2008 It could be, but it's impossible to tell until Cha0sBG learns to be more preciseTrue, I probably wasted my time. 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...
Andreik Posted August 20, 2008 Share Posted August 20, 2008 (edited) True, I probably wasted my time.No, you not waste your time for nothing, I`m sure that somebody learn from your example. Edited August 20, 2008 by Andreik When the words fail... music speaks. 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