![]() ![]() ![]() ![]() Even the word "sort" will not be shown as the Xojo IDE knows that // an array can not be sorted (out-of-the-box) if it contains classes. results.sort(addressof vehicleCompareCar ) // Exporting the array again, is now showing that the entries got sorted. output = output + "RESULTS after SORTING:" + endofline + endofline For each result as vehicle in results output = output + result.driver + " | " + result.car + EndOfLine next taResults.value = output So in case you have the need of a multidimensional array, it is best // to transfer the variables into a class and add those classes to a one-dimensional array, // which you can sort with your own logic. Please note that we are writing an own method to sort our one-dimensional array, containing the class instances. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |