Herb191 Posted September 18, 2010 Posted September 18, 2010 Why is “Amortization Table” not showing up as white? #include <GUIConstantsEx.au3> #include <ButtonConstants.au3> $Form1_1 = GUICreate("Amortization Plus", 644, 303, 207, 200) GUISetBkColor(0x000080) $Group1 = GUICtrlCreateGroup("Amortization Table", 8, 0, 625, 81, BitOR($BS_CENTER, $BS_FLAT)) GUICtrlSetColor(-1, 0xFFFFFF) GUICtrlSetFont(-1, 10, 400, 0, "System") GUISetState(@SW_SHOW) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd
wakillon Posted September 18, 2010 Posted September 18, 2010 Read helpfile ! GUICtrlSetColor :RemarksOnly Button, Label, Checkbox, Group, Radio, Edit, Input, List, Listview, ListviewItem, Treeview, TreeviewItem, Graphic, Progress and Combo controls can currently be colored.Checkbox, Radio, Group or Progress controls cannot be painted if the "Windows XP/Vista style" is used.Button controls are always painted in "Windows Classic style".between us, I did not know either ! AutoIt 3.3.18.0 X86 - SciTE 4.4.6.0 - WIN 11 24H2 X64 - Other Examples Scripts
AdmiralAlkex Posted September 18, 2010 Posted September 18, 2010 You can make only the group-control run without any theme by doing like so: #include <GUIConstantsEx.au3> #include <ButtonConstants.au3> $Form1_1 = GUICreate("Amortization Plus", 644, 303, 207, 200) GUISetBkColor(0x000080) $Group1 = GUICtrlCreateGroup("Amortization Table", 8, 0, 625, 81, BitOR($BS_CENTER, $BS_FLAT)) DllCall("UxTheme.dll", "int", "SetWindowTheme", "hwnd", GUICtrlGetHandle($Group1), "wstr", 0, "wstr", 0) GUICtrlSetColor(-1, 0xFFFFFF) GUICtrlSetFont(-1, 10, 400, 0, "System") GUISetState(@SW_SHOW) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd (this of course also works on Checkbox, Radio and Progress) Or disable it for the whole gui like so: #include <GUIConstantsEx.au3> #include <ButtonConstants.au3> DllCall("uxtheme.dll", "none", "SetThemeAppProperties", "int", 0) $Form1_1 = GUICreate("Amortization Plus", 644, 303, 207, 200) GUISetBkColor(0x000080) $Group1 = GUICtrlCreateGroup("Amortization Table", 8, 0, 625, 81, BitOR($BS_CENTER, $BS_FLAT)) GUICtrlSetColor(-1, 0xFFFFFF) GUICtrlSetFont(-1, 10, 400, 0, "System") GUISetState(@SW_SHOW) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit EndSwitch 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
Herb191 Posted September 18, 2010 Author Posted September 18, 2010 Read helpfile ! GUICtrlSetColor :between us, I did not know either ! Thanks.
Herb191 Posted September 18, 2010 Author Posted September 18, 2010 You can make only the group-control run without any theme by doing like so: #include <GUIConstantsEx.au3> #include <ButtonConstants.au3> $Form1_1 = GUICreate("Amortization Plus", 644, 303, 207, 200) GUISetBkColor(0x000080) $Group1 = GUICtrlCreateGroup("Amortization Table", 8, 0, 625, 81, BitOR($BS_CENTER, $BS_FLAT)) DllCall("UxTheme.dll", "int", "SetWindowTheme", "hwnd", GUICtrlGetHandle($Group1), "wstr", 0, "wstr", 0) GUICtrlSetColor(-1, 0xFFFFFF) GUICtrlSetFont(-1, 10, 400, 0, "System") GUISetState(@SW_SHOW) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd (this of course also works on Checkbox, Radio and Progress) Or disable it for the whole gui like so: #include <GUIConstantsEx.au3> #include <ButtonConstants.au3> DllCall("uxtheme.dll", "none", "SetThemeAppProperties", "int", 0) $Form1_1 = GUICreate("Amortization Plus", 644, 303, 207, 200) GUISetBkColor(0x000080) $Group1 = GUICtrlCreateGroup("Amortization Table", 8, 0, 625, 81, BitOR($BS_CENTER, $BS_FLAT)) GUICtrlSetColor(-1, 0xFFFFFF) GUICtrlSetFont(-1, 10, 400, 0, "System") GUISetState(@SW_SHOW) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd Cool I was looking for a work around thanks!
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