Options

Is there any way to sort Integer Dimensions?

vinceliu666vinceliu666 Member Posts: 51
I use an Integer Dimensions and I want to sort dimensions value from small to big. Is there any way to do ? Just like ArrayList.Sort() in C#.

Best Answers

Answers

  • Options
    vinceliu666vinceliu666 Member Posts: 51
    Hi Vaprog:
    Thanks for your relpy. Finally, I found an article to solve it by using bubble sort.

    https://community.dynamics.com/nav/b/technicalfindingsindynamicsnav/posts/bubble-sort-in-c-al
  • Options
    vaprogvaprog Member Posts: 1,118
    Why don't you use a temporary instance of Integer table? This avoids having to decide on an arbitrarily sized array, you do not have to implement a sorting algorithm, and it is probably faster anyway.
  • Options
    vinceliu666vinceliu666 Member Posts: 51
    Hi vaprog:
    I don't really understand how to use temporary instance of integer table?Could you ,please ,provide sample code?
  • Options
    vinceliu666vinceliu666 Member Posts: 51
    Hi vaprog :
    Thanks for providing the sample code.
Sign In or Register to comment.