JS1232: Package declaration not allowed in this context

A package declaration appears in a context other than the global scope. This is not allowed; packages can only be declared in the global scope.

To correct this error

  • Make sure all packages are declared in the global scope.

See Also

Reference

package Statement

Concepts

Troubleshooting Your Scripts

Other Resources

JScript Reference