Are you using the script in View mode?
# suitescript
e
Are you using the script in View mode?