simple script that does not work in scheduler

I have a 2 scripts which have almost same line. Both run fine if I execute them manually. But when I run them from script or scheduler, it won’t work. This is really strange and frustrating.

The script is as below:
script-a
/interface ethernet switch ingress-port-policer disable number=0

script-b
/interface ethernet switch ingress-port-policer disable number=1

Problem:
script-a runs fine under scheduler but script-b does not work.

  1. if I use commandline to “/system script run script-b” it will work
  2. if I click on “run script” or let the scheduler run the script it will not work for script-b (script-a works)
  3. i have tried removing and adding “enter” at the end of the line for both scripts but still the same. script-a works perfectly but script-b does not work under scheduler.

Anyone have any idea how to solve this? Mikrotik’s scripts is really very broken.

I had 2 scripts that stopped working after I made changes to them. A third script that was almost identical to the 2 worked fine. I had to delete them and re-add them for them to work again. This was after I spent 3 days trying to figure out why they weren’t working.

thanks for the quick reply. i tried removing the script and re-adding but still does not run from run-script or from scheduler. Directly running it or using “/system script run script-b” works

anyone have any other ideas? I really need to get this working…