Change script issue is throwing an error

Please see Wiki - how to post code on this forum.