A community member has associated this post with a similar question:
Power Automate Network sync during Excel Office Script While Loop
Only moderators can edit this content.
Office script does not fully run in power automate (while loop) works in excel
I am working on a automation project for my department. This is my first attempt at using power automate / office script. There may be a better way to do this process. I am open to suggestions.
The sheet
I have created a random schedule for an internal process. I used a formula to sample the names randomly without replication. Then I count the total occurances of each name. Next to that I have a conditional column that is false if everyone is not assigned evenly.
The script
The script first changes two cells with a random number. This means the schedule will be shuffled at least once per run. Next, a while statement will keep shuffling until all names are assigned 4 times which turns cell E17 to 1 stopping the loop.
Whats different
The loop runs the first portion of code in power automate but does not run the while loop. The script runs properly in excel.