Ocean West Posted February 25, 2009 Posted February 25, 2009 using a technique to sort portal items if i want to move an item up or down add an decimal to the sort order, like 2.5 will place item between 1 and 2. Then I run a script trigger after that to perform an operation that would re-serialize the sort order. Option A GTRR to the portal records, sort, go to the first then replace 1 increment by 1 then go back to original layout. (or use off screen window { haven't tested on windows may create window dancing } ) Option B Loop thru the portal resetting the sort number incrementing accordingly. Which would be cleaner and most efficient? thanx S
Ocean West Posted February 26, 2009 Author Posted February 26, 2009 Thats how i have it setup now however, I think that returning to the original layout will require capturing current state (tab panels / portal row selected ) prior to executing the script so that you don't loose focus if you have nested tabs?!
wintergreen Posted February 26, 2009 Posted February 26, 2009 Neither method is best. You don't want to update all the fields in the group. Just swap the two adjacent numbers like so: 1. A 2. B 3. C 4. D To move B down the list, set record B to 3, set record C to 2. 1. A 2. C 3. B 4. D
Ocean West Posted February 26, 2009 Author Posted February 26, 2009 not exactly you need to resequenced all numbers after the change... Original Portal 1. a 2. b 3. c 4. d 5. e ~ 23. w 24. x 25. y 26. z MOVE ITEM x below c 1. a 2. b 3. c 4. x 5. d ~ 23. v 24. w 25. y 26. z
wintergreen Posted February 26, 2009 Posted February 26, 2009 Ah, I see. You want to be able to move an item more than one place in a single operation. In which case I would probably opt for A. A freeze window will probably prevent the screen moving too.
Fenton Posted February 26, 2009 Posted February 26, 2009 An interesting question, as to which would be faster and smoother looking. An alternative idea, if you were never showing the numbers, would be to not renumber them, but just leave them as decimal numbers. You would never run out of decimals.
Recommended Posts
This topic is 5747 days old. Please don't post here. Open a new topic instead.
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