Script to automatically renumber other records when one is manually renumbered
Hi, I have a product list which is sorted numerically in ascending order (see picture). The Product Numbers are editable, and the list resorts automatically. However, I need a script to automatically renumber the records i didn't modify to avoid duplicate Product Numbers. ObjectModify will trigger this script.
Example with picture below:
-If I change 6 to 8, 7 and 8 should become 6 and 7.
-If I change 8 to 6, 6 and 7 should become 7 and 8.
Any ideas? I'm pretty new to this so go easy on me.