I have items in array
I need to get from array this:
1st Call:
4 1 2
2st Call:
1 2 3
3st Call:
2 3 4
4st Call:
3 4 1
5st Call:
4 1 2
So as you can see it start with LAST_ITEM | FIRST_ITEM | SECOND_ITEM
And then incrementing each of three items by one.
This i need for horizontal scroller when i press LEFT Button....When i press RIGHT button it needs to get inverse...
I search forum but could not find function for sort array like i need. I can make it manuall but i like it to calculate thease numbers in example automatically.
B4X:
Dim Items() As Int = Array As Int (1, 2, 3, 4)
I need to get from array this:
1st Call:
4 1 2
2st Call:
1 2 3
3st Call:
2 3 4
4st Call:
3 4 1
5st Call:
4 1 2
So as you can see it start with LAST_ITEM | FIRST_ITEM | SECOND_ITEM
And then incrementing each of three items by one.
This i need for horizontal scroller when i press LEFT Button....When i press RIGHT button it needs to get inverse...
I search forum but could not find function for sort array like i need. I can make it manuall but i like it to calculate thease numbers in example automatically.