enigmaforceiv Posted September 3, 2012 Posted September 3, 2012 (edited) I would like to change the font color of a GUICtrlCreateLabel from default black into another color - the problem I'm having is that I don't want it to be the global text color, instead, I want it to pertain just to the specific text. Edited September 3, 2012 by enigmaforceiv
water Posted September 3, 2012 Posted September 3, 2012 Where? In Word, in Excel, in a GUI control ....? My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki
FireFox Posted September 3, 2012 Posted September 3, 2012 (edited) Hi, Can you duplicate the question from the topic to your post please? I made few seconds to understand it was an arrow indicating "read the title". Let's say you want to change the font color in your GUI, then it's not by the function GuiCtrlSetFont, but with the function GuiCtrlSetColor. Br, FireFox. Edited September 3, 2012 by FireFox
enigmaforceiv Posted September 3, 2012 Author Posted September 3, 2012 Updated, sorry was at that "point" of knocking out trying to figure out this new issue! haha
Danyfirex Posted September 3, 2012 Posted September 3, 2012 example. label <GUIConstantsEx.au3> Example() Func Example() Local $widthCell, $msg, $iOldOpt GUICreate("My GUI") ; will create a dialog box that when displayed is centered GUISetHelp("notepad.exe") ; will run notepad if F1 is typed $iOldOpt = Opt("GUICoordMode", 2) $widthCell = 70 GUICtrlCreateLabel("Line 1 Cell 1", 10, 30, $widthCell) ; first cell 70 width GUICtrlSetColor(-1,0xdf234d) GUICtrlCreateLabel("Line 2 Cell 1", -1, 0) ; next line GUICtrlSetColor(-1,0xfddf23) GUICtrlCreateLabel("Line 3 Cell 2", 0, 0) ; next line and next cell GUICtrlSetColor(-1,0xFFFFFF) GUICtrlCreateLabel("Line 3 Cell 3", 0, -1) ; next cell same line GUICtrlSetColor(-1,0x833454) GUICtrlCreateLabel("Line 4 Cell 1", -3 * $widthCell, 0) ; next line Cell1 GUICtrlSetColor(-1,0x346323) GUISetState() ; will display an empty dialog box ; Run the GUI until the dialog is closed Do $msg = GUIGetMsg() Until $msg = $GUI_EVENT_CLOSE $iOldOpt = Opt("GUICoordMode", $iOldOpt) EndFunc ;==>Example Danysys.com AutoIt... UDFs: VirusTotal API 2.0 UDF - libZPlay UDF - Apps: Guitar Tab Tester - VirusTotal Hash Checker Examples: Text-to-Speech ISpVoice Interface - Get installed applications - Enable/Disable Network connection PrintHookProc - WINTRUST - Mute Microphone Level - Get Connected NetWorks - Create NetWork Connection ShortCut
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