Hi David,
Often these types of problems are related to security, as ActiveSMS will run you script using a LocalSystem account rather than your own login.
I would suggest adding trace logging to your script, i.e. write progress updates to a file. This should allow you to see how far your script gets before it has a problem.