jercfd Posted June 12, 2008 Share Posted June 12, 2008 Why is the limit for numbers in autoit -9223372036854775807 through 9223372036854775807? Some example code to prove it expandcollapse popup#include <GUIConstants.au3> #include <WindowsConstants.au3> #include <ListBoxConstants.au3> Opt("GUIOnEventMode", 1) GUICreate("The number that goes on forever and forever", 425, 135, -1, -1, BitOR($WS_CAPTION, $WS_POPUP, $WS_BORDER, $WS_CLIPSIBLINGS), BitOR($WS_EX_TOOLWINDOW, $WS_EX_TOPMOST, $WS_EX_WINDOWEDGE)) $Start = GUICtrlCreateLabel("Time Started:", 5, 5, 200, 17) $Number = GUICtrlCreateLabel("Current Number: ", 5, 25, 200, 17) $End = GUICtrlCreateLabel("Time Ended: ", 5, 45, 200, 17) $ButtonGo = GUICtrlCreateButton("Start", 5, 70, 55, 25, 0) GUICtrlSetOnEvent(-1, "_Start") $Buttonstop = GUICtrlCreateButton("Stop", 70, 70, 55, 25, 0) GUICtrlSetOnEvent(-1, "_Stop") $Exit = GUICtrlCreateButton("Exit", 135, 70, 55, 25, 0) GUICtrlSetOnEvent(-1, "_Exit") GUICtrlCreateGroup("Numbers Gone Though", 210, 5, 210, 125) $List = GUICtrlCreateList("", 215, 25, 200, 97, BitOR($LBS_NOSEL, $WS_BORDER, $WS_VSCROLL)) GUICtrlCreateGroup("", -99, -99, 1, 1) GUICtrlCreateLabel("Move mouse over for more information.", 5, 115, 200, 17) GUICtrlSetTip(-1, "The range of numbers this program can handle is -9223372036854775807 through 9223372036854775807") GUICtrlSetState($Buttonstop, $GUI_DISABLE) GUISetState(@SW_SHOW) Global $On = False $i = 9223372036854775800 While 1 If $On Then _Action() WEnd Func _Start() $On = True GUICtrlSetState($ButtonGo, $GUI_DISABLE) GUICtrlSetState($Buttonstop, $GUI_ENABLE) GUICtrlSetData($Start, "Time Started: " & @MON & "/" & @MDAY & "/" & @YEAR & " " & @HOUR & ":" & @MIN & ":" & @SEC) GUICtrlSetData($Number, "Current Number: ") GUICtrlSetData($End, "Time Ended: ") EndFunc Func _Stop() $On = False GUICtrlSetState($ButtonGo, $GUI_ENABLE) GUICtrlSetState($Buttonstop, $GUI_DISABLE) GUICtrlSetData($End, "Time Ended: " & @MON & "/" & @MDAY & "/" & @YEAR & " " & @HOUR & ":" & @MIN & ":" & @SEC) EndFunc Func _Exit() Exit EndFunc Func _Action() GUICtrlSetData($Number, "Current Number: " & $i) GUICtrlSetData($List, $i & "|") $i = $i + 1 EndFunc Link to comment Share on other sites More sharing options...
DaveF Posted June 12, 2008 Share Posted June 12, 2008 Check the AutoIt3 help file, Frequently Asked Questions, Item 15. Yes yes yes, there it was. Youth must go, ah yes. But youth is only being in a way like it might be an animal. No, it is not just being an animal so much as being like one of these malenky toys you viddy being sold in the streets, like little chellovecks made out of tin and with a spring inside and then a winding handle on the outside and you wind it up grrr grrr grrr and off it itties, like walking, O my brothers. But it itties in a straight line and bangs straight into things bang bang and it cannot help what it is doing. Being young is like being like one of these malenky machines. 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