Jump to content

ju4711

Members
  • Posts

    4
  • Joined

  • Last visited

ju4711's Achievements

Seeker

Seeker (1/7)

0

Reputation

  1. Thank you very much. I appreciate it
  2. oh. Well, if $Error is checked, the programm should change the data of $FinalIcon to 16 so that the msgbox showes the right icon. I guess that would mean... After the "GuiCtrlRead($FinalIcon)" there should be an Endif. (Im not sure tbh :/)
  3. Well , youre right. I will just copy and paste the whole script in here: #include <ButtonConstants.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #Region ### START Koda GUI section ### Form= $Form1_1 = GUICreate("My MsgBox", 654, 221, 174, 117) $Exit = GUICtrlCreateMenu("&Exit") $Credits = GUICtrlCreateMenu("&Credits") $Help = GUICtrlCreateMenu("&Help") $Generate = GUICtrlCreateButton("Generate", 248, 128, 155, 49) $Error = GUICtrlCreateRadio("Error (Icon)", 32, 48, 115, 17) GUICtrlSetState(-1, $GUI_CHECKED) $Warning = GUICtrlCreateRadio("Warning (Icon)", 32, 96, 115, 17) $Information = GUICtrlCreateRadio("Information (Icon)", 32, 144, 115, 17) $Title = GUICtrlCreateInput("Type in your title here.", 248, 48, 153, 21) $Message = GUICtrlCreateInput("Type in your message here.", 248, 88, 153, 21) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### #NoTrayIcon While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $Generate $FinalIcon = If GUICtrlRead($Error) = $GUI_CHECKED Then GUICtrlSetData($FinalIcon,16) GUICtrlRead($FinalIcon) $FinalTitle = GUICtrlRead($Title) $FinalMessage = GUICtrlRead($Message) MsgBox($FinalIcon,$FinalTitle,$FinalMessage) Okay, i hope you can work with that xd ^^. $Error for example is just the radio field button to choose an icon and $FinalError is that what comes out from "GuiCtrlRead"
  4. Hello Guys. I want to create a little programm where you can make messageboxes and save them (for people who dont know how to do that themself :3). I have some kinda radio field buttons to decide what icon the messagebox should show. With the inputboxes, i do it like this: $FinalTitle = GUICtrlRead($Title) $FinalMessage = GUICtrlRead($Message) MsgBox($FinalIcon,$FinalTitle,$FinalMessage) But for some reason the one with the icon does not work properly: $FinalIcon = If GUICtrlRead($Error) = 1 Then <syntax error> GUICtrlSetData($FinalIcon,16) Please help me, im a noob
×
×
  • Create New...