tnok85 0 Posted January 29, 2011 #include <Array.au3> Local $avArray[11] = [1, 5, 1, 7, 66, 12, 1, 66, 11, 5, 1] MsgBox(0,'Min Index Numeric value', _ArrayMinIndex($avArray, 1)) MsgBox(0,'Max Index Numeric value', _ArrayMaxIndex($avArray, 1)) It seems to only return the first min and first max. (Min shows 0, max shows 4) I'd like to have it show you *all* minimums and *all* maximums if there is more than one min or max. Share this post Link to post Share on other sites
KaFu 295 Posted January 29, 2011 Then wrap the functions in an enumeration: #include <Array.au3> Local $avArray[11] = [1, 5, 1, 7, 66, 12, 1, 66, 11, 5, 1] Local $i_ArrayMin = $avArray[_ArrayMinIndex($avArray, 1)] For $i = 0 To UBound($avArray) - 1 If $avArray[$i] = $i_ArrayMin Then ConsoleWrite("Min " & $i_ArrayMin & " found at " & $i & @CRLF) Next Local $i_ArrayMax = $avArray[_ArrayMaxIndex($avArray, 1)] For $i = 0 To UBound($avArray) - 1 If $avArray[$i] = $i_ArrayMax Then ConsoleWrite("Max " & $i_ArrayMax & " found at " & $i & @CRLF) Next OS: Win10-1909 - 64bit - German, AutoIt Version: 3.3.14.5, AutoIt Editor: SciTE, Website: https://funk.eu AMT - Auto-Movie-Thumbnailer (2019-Dec-21) BIC - Batch-Image-Cropper (2019-Dec-11) COP - Color Picker (2009-May-21) HMW - Hide my Windows (2018-Sep-16) HRC - HotKey Resolution Changer (2012-May-16) ICU - Icon Configuration Utility (2018-Sep-16) SMF - Search my Files (2019-Dec-07) - THE file info and duplicates search tool SSD - Set Sound Device (2017-Sep-16) Share this post Link to post Share on other sites