litlmike Posted May 21, 2008 Share Posted May 21, 2008 I would like to make a GUI with several behaviors, but I would like to brainstorm with our community before I embark, because I can foresee several problems arising that I do not know if there are solutions for. I included a dummy GUI just for a visual idea of what I am looking to do, along with a description of the behaviors desired. Also, a list of issues that I am unaware of how to resolve. Thanks in advance for any direction you can provide.Behaviors:User Runs Gui that appears as a Plain Gui with several Add buttons. If User presses Add SF, then Gui Resizes and Adds the Appropriate ComboBox.If User presses Add FA, then Gui Resizes and Adds the Appropriate ComboBoxIf User presses Remove SF (or FA), then Gui Resizes and Removes the Appropriate ComboBoxIn the Event that User types in their own value into a ComboBox, GUI Recalcs the values in InputBoxes User Presses "Done" and GUI calls FuncIssues1) Possilbe to Resize Gui? Or must Delete and Re-Create?2) Can OnEvent mode work if user types a value into the ComboBox rather than selecting? When I tried, it didn't work.3) How can I calculate values or set behaviors for Controls not yet created? In other words, I will need to GuiCtrlRead a ComboBox to Calculate and GuiCtrlSetData for a GuiCtrlInput. But how can I declare a function to do so? It seems that it will be an issue to Assign the ComboBoxes as Variables.4) Is OnEvent mode, the direction I should take with this GUI?#include <ButtonConstants.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <StaticConstants.au3> #include <WindowsConstants.au3> #Region ### START Koda GUI section ### $Form2 = GUICreate("Dialog", 405, 346, 321, 254) GUISetIcon("D:\004.ico") $GroupBox1 = GUICtrlCreateGroup("Add GuiCtrls In Here", 8, 5, 265, 250) GUICtrlCreateGroup("", -99, -99, 1, 1) $Button1 = GUICtrlCreateButton("&OK", 286, 11, 75, 25, 0) $Button2 = GUICtrlCreateButton("&Cancel", 285, 44, 75, 25, 0) $Button3 = GUICtrlCreateButton("&Done", 285, 76, 75, 25, 0) $Button4 = GUICtrlCreateButton("Add SF", 285, 110, 75, 25, 0) $Button5 = GUICtrlCreateButton("Add FA", 285, 145, 75, 25, 0) $Button6 = GUICtrlCreateButton("&Remove SF", 285, 182, 75, 25, 0) $Button7 = GUICtrlCreateButton("Remove FA", 285, 217, 75, 25, 0) $Input1 = GUICtrlCreateInput("Total Price", 285, 275, 85, 21) $Input2 = GUICtrlCreateInput("Total Reduction", 285, 300, 85, 21) $Input3 = GUICtrlCreateInput("Total Value", 285, 250, 85, 21) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd _ArrayPermute()_ArrayUnique()Excel.au3 UDF 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