Sign in to follow this  
Followers 0
redjester45

Its simple but i cant figure it out

3 posts in this topic

I know its something simple but I can't for the life of me figure out why its returning 1.5 when I input 100 into the first input box and 500 into the second. Any help pointing me in the right direction would be super.

#include <GUIConstants.au3>


#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("Form1", 187, 588, 193, 115)
$Label12 = GUICtrlCreateLabel("How many can you hold?", 38, 14, 124, 17)
$var1 = GUICtrlCreateInput("", 47, 32, 65, 21)
$Label13 = GUICtrlCreateLabel("How many do you want?", 20, 73, 150, 17)
$var2 = GUICtrlCreateInput("", 30, 95, 129, 21)
$Button1 = GUICtrlCreateButton("Start", 40, 168, 81, 25, 0)
$Var3 = GUICtrlCreateInput("", 24, 144, 113, 21)
GUISetState()
#EndRegion ### END Koda GUI section ###


While 1
          $nMsg = GUIGetMsg()
    Select 
        Case $nMsg = $GUI_EVENT_CLOSE
            ExitLoop
        Case $nMsg = $Button1
                
            GuiCtrlSetData($var3,$var2 / $var1,"")
    EndSelect
WEnd

Share this post


Link to post
Share on other sites



Cool beans. thanx

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0