minxomat Posted November 6, 2015 Share Posted November 6, 2015 AutoIt usually catches array sizes that make no sense:ConsoleWrite("> " & @AutoItVersion & @LF) Dim $_[9e9](2) : ==> Variable subscript badly formatted.: Dim $_[9e9] Dim $_[^ ERROR ->12:23:54 AutoIt3.exe ended.rc:1 +>12:23:54 AutoIt3Wrapper Finished.But, ConsoleWrite("> " & @AutoItVersion & @LF) Dim $_[1e9]--> Press Ctrl+Alt+Break to Restart or Ctrl+Break to Stop > 3.3.14.2 !>12:25:16 AutoIt3.exe ended.rc:-1073741819 +>12:25:16 AutoIt3Wrapper Finished. >Exit code: 3221225477 Time: 7.2 Only occurs in 3.3.14.2 for me. I will answer every single PM, and you are free to ask anything anytime. Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted November 6, 2015 Moderators Share Posted November 6, 2015 minxomat,With v3.3.14.2 I get an error flagged both with and without Au3Check:ConsoleWrite("> " & @AutoItVersion & @LF) Dim $_[9e9]>Running:(3.3.14.2):M:\Program\AutoIt3\autoit3.exe "M:\Program\Au3 Scripts\fred4.au3" --> Press Ctrl+Alt+Break to Restart or Ctrl+Break to Stop > 3.3.14.2 "M:\Program\Au3 Scripts\fred4.au3" (3) : ==> Variable subscript badly formatted.: Dim $_[9e9] Dim $_[^ ERROR ->11:33:05 AutoIt3.exe ended.rc:1 +>11:33:05 AutoIt3Wrapper Finished.#AutoIt3Wrapper_Run_AU3Check=n ConsoleWrite("> " & @AutoItVersion & @LF) Dim $_[9e9]>Running:(3.3.14.2):M:\Program\AutoIt3\autoit3.exe "M:\Program\Au3 Scripts\fred4.au3" --> Press Ctrl+Alt+Break to Restart or Ctrl+Break to Stop > 3.3.14.2 "M:\Program\Au3 Scripts\fred4.au3" (4) : ==> Variable subscript badly formatted.: Dim $_[9e9] Dim $_[^ ERROR ->11:31:43 AutoIt3.exe ended.rc:1 +>11:31:43 AutoIt3Wrapper Finished.M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
minxomat Posted November 6, 2015 Author Share Posted November 6, 2015 Yes, same for me, because you tried the working snippet twice, now try the other. I will answer every single PM, and you are free to ask anything anytime. Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted November 6, 2015 Moderators Share Posted November 6, 2015 minxomat,I see it now - sorry about that.M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
minxomat Posted November 6, 2015 Author Share Posted November 6, 2015 I see it nowDoes it crash for you? I will answer every single PM, and you are free to ask anything anytime. Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted November 6, 2015 Moderators Share Posted November 6, 2015 minxomat,Yes, I get the same result as you - using [9e9] errors, using [1e9] crashes - but I have no idea why as I would have expected both to result in errors. You say it only happens in 3.3.14.2, have you checked in 3.3.14.0/1?M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
minxomat Posted November 6, 2015 Author Share Posted November 6, 2015 have you checked in 3.3.14.0/1?No. I know that it is impossible to check array bounds at runtime if they depend on other lines of code (Halting Problem), but I think this constant expression should produce an error in any case where it evaluates to >16777216. Or is this intended behavior? I will answer every single PM, and you are free to ask anything anytime. Link to comment Share on other sites More sharing options...
UEZ Posted November 6, 2015 Share Posted November 6, 2015 Is 1e9 something like 1*10^9? Please don't send me any personal message and ask for support! I will not reply! Selection of finest graphical examples at Codepen.io The own fart smells best! ✌Her 'sikim hıyar' diyene bir avuç tuz alıp koşma!¯\_(ツ)_/¯ ٩(●̮̮̃•̃)۶ ٩(-̮̮̃-̃)۶ૐ Link to comment Share on other sites More sharing options...
minxomat Posted November 6, 2015 Author Share Posted November 6, 2015 Is 1e9 something like 1*10^9?Yes, scientific notation for programming languages. I will answer every single PM, and you are free to ask anything anytime. Link to comment Share on other sites More sharing options...
water Posted November 6, 2015 Share Posted November 6, 2015 I think it is a problem with AutoIt not interpreting 1e9 as a number.When I try the following code with 3.3.15.0 I get "Map" as the variable type.ConsoleWrite("> " & @AutoItVersion & @LF) Dim $_[9e9] ConsoleWrite(VarGetType($_) & @CRLF) 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 Link to comment Share on other sites More sharing options...
UEZ Posted November 6, 2015 Share Posted November 6, 2015 Your example could be simplified toGlobal $a[1000000000]which crashes also. Please don't send me any personal message and ask for support! I will not reply! Selection of finest graphical examples at Codepen.io The own fart smells best! ✌Her 'sikim hıyar' diyene bir avuç tuz alıp koşma!¯\_(ツ)_/¯ ٩(●̮̮̃•̃)۶ ٩(-̮̮̃-̃)۶ૐ Link to comment Share on other sites More sharing options...
minxomat Posted November 6, 2015 Author Share Posted November 6, 2015 I think it is a problem with AutoIt not interpreting 1e9 as a number.When I try the following code with 3.3.15.0 I get "Map" as the variable type.ConsoleWrite("> " & @AutoItVersion & @LF) Dim $_[9e9] ConsoleWrite(VarGetType($_) & @CRLF) It runs? I guess(!) this is because it is out of any array bounds valid for AutoIt. Maybe Maps can have more elements. I will answer every single PM, and you are free to ask anything anytime. Link to comment Share on other sites More sharing options...
minxomat Posted November 6, 2015 Author Share Posted November 6, 2015 Your example could be simplified toGlobal $a[1000000000]which crashes also.This is exactly the same. You could also write 10000000*10, it'll be the same number - that's not the problem. I will answer every single PM, and you are free to ask anything anytime. Link to comment Share on other sites More sharing options...
TheDcoder Posted November 6, 2015 Share Posted November 6, 2015 From here:VAR_SUBSCRIPT_ELEMENTS = 16,777,216 (This is the limit of elements in an Array)9e9 (9000000000) is wayyyyy more than 16,777,216 BrewManNH 1 EasyCodeIt - A cross-platform AutoIt implementation - Fund the development! (GitHub will double your donations for a limited time) DcodingTheWeb Forum - Follow for updates and Join for discussion Link to comment Share on other sites More sharing options...
minxomat Posted November 6, 2015 Author Share Posted November 6, 2015 (edited) @TheDcoder Did you even read my posts?I know that it is impossible to check array bounds at runtime if they depend on other lines of code (Halting Problem), but I think this constant expression should produce an error in any case where it evaluates to >16777216. Or is this intended behavior? Edited November 6, 2015 by minxomat I will answer every single PM, and you are free to ask anything anytime. Link to comment Share on other sites More sharing options...
water Posted November 6, 2015 Share Posted November 6, 2015 From here:9e9 (9000000000) is wayyyyy more than 16,777,216 But you should then get error message "Array maximum size exceeded." and not "Variable subscript badly formatted." 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 Link to comment Share on other sites More sharing options...
minxomat Posted November 6, 2015 Author Share Posted November 6, 2015 (edited) "Array maximum size exceeded."I'm not able to produce this error. Can you post an example?---Meanwhile other test cases:ConsoleWrite("> " & @AutoItVersion & @LF) Global Const $iArrayMax = 16777216 Global Const $iOverflow = 16777777 Local $1[$iOverflow] ; crash Global $1[$iOverflow] ; crash Dim $1[$iOverflow] ; crash Local $2[$iArrayMax] ReDim $2[$iArrayMax + 1] ; crash Local $3[3.141] ; works fine ConsoleWrite("!> Bound: " & UBound($3) & @LF) Edited November 6, 2015 by minxomat I will answer every single PM, and you are free to ask anything anytime. Link to comment Share on other sites More sharing options...
TheDcoder Posted November 6, 2015 Share Posted November 6, 2015 @minxomat Oh, sorry, miss it ...@water Strange it, it crashes for me when it exceeds 16,777,216 (No errors, nothing, just crash message) EasyCodeIt - A cross-platform AutoIt implementation - Fund the development! (GitHub will double your donations for a limited time) DcodingTheWeb Forum - Follow for updates and Join for discussion Link to comment Share on other sites More sharing options...
water Posted November 6, 2015 Share Posted November 6, 2015 Sure. I get "Array maximum size exceeded." with AutoIt 3.3.12.0ConsoleWrite("> " & @AutoItVersion & @LF) Global $iElements = 9000000000 Global $aArray[$iElements] 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 Link to comment Share on other sites More sharing options...
minxomat Posted November 6, 2015 Author Share Posted November 6, 2015 Strange it, it crashes for me when it exceeds 16,777,216 (No errors, nothing, just crash message)Congratulations, you found out what this thread is about! water and TheDcoder 2 I will answer every single PM, and you are free to ask anything anytime. 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