ANS-1482 · SUITESCRIPT DEVELOPMENT
Why Does NetSuite Script Execution Return MODULE_DOES_NOT_EXIST Error?
Ensure JavaScript file names in NetSuite's File Cabinet include the .js extension to prevent script execution failures.
Short answer
The NetSuite MODULE_DOES_NOT_EXIST error for scripts often occurs when the JavaScript file record in the File Cabinet is missing the .js extension in its name. Even if NetSuite identifies the file type correctly, the script will fail to execute without the proper extension. Adding .js to the file name resolves the issue.
Scenario
Users may encounter a MODULE_DOES_NOT_EXIST error when attempting to execute a script in NetSuite, despite verifying that the script file exists in the File Cabinet. This error indicates that NetSuite cannot locate or properly reference the script module, even when it appears to be present.
Solution
To resolve the MODULE_DOES_NOT_EXIST error related to script execution, ensure that the JavaScript file record in NetSuite's File Cabinet includes the .js extension in its name.
Navigate to the File Cabinet and locate the script file in question.
Edit the file record and verify its name.
If the file name is missing the .js extension, add it to the end of the name (e.g., myScript should become myScript.js).
Save the updated file record.Even if the File record itself correctly identifies the file as a Javascript file, the script will fail to execute if the name does not end with .js. Including the extension ensures the script runs correctly.
Expert NetSuite Support
Need help with this NetSuite issue?
SuiteScript Development consulting and configuration support
