Creating a SuiteScript File in SuiteCloud Extension for Visual Studio Code
You can use NetSuite SuiteScript scripting language to extend NetSuite and customize, search, and process your NetSuite data. From a SuiteCloud project, you can create a SuiteScript file based on a script type template, including any modules you pick. For more information about SuiteScript, see SuiteScript Overview.
To create a SuiteScript file:
-
In VS Code, open the SuiteCloud project where you want to create the SuiteScript file.
-
Open the Command Palette and type
suitecloud
.From the dropdown, pick SuiteCloud: Create SuiteScript File.
-
From the dropdown, pick the type of SuiteScript file type you want to create and press Enter. For example, picking
Map/Reduce Script
creates a file based on the Map/Reduce script template.For information about the list of available SuiteScript script types, see SuiteScript 2.x Script Types.
-
From the dropdown, pick the SuiteScript modules you want to add to the file, and click OK. For example,
N/currency
. You can pick one, several, all of them, or none.Scroll down the list to see all the available SuiteScript modules.
For the list of available SuiteScript modules, see SuiteScript 2.x Modules.
-
Pick the folder where you want to create the SuiteScript file and press Enter. For example, a
FileCabinet
folder in a SuiteApp project might be/SuiteApps/com.example.currency
. Only valid folders in your SuiteCloud project show up.For information about where SuiteScript files can be stored in SuiteCloud projects, see SuiteCloud Project Structure and File Components.
-
Enter a name for the SuiteScript file you're creating. For example,
currency.js
. If you don't add the file extension.js
, it'll be added for you.The SuiteScript file is created in the folder you picked and opened for editing in VS Code. The file contents are based on the template for the SuiteScript type you chose, with your selected modules added to the code.
Related Topics
- SuiteCloud Extension for Visual Studio Code Usage
- Creating a SuiteCloud Project in SuiteCloud Extension for Visual Studio Code
- Setting Up NetSuite Accounts in SuiteCloud Extension for Visual Studio Code
- Managing NetSuite Accounts in SuiteCloud Extension for Visual Studio Code
- Listing SDF Custom Objects in SuiteCloud Extension for Visual Studio Code
- Updating SDF Custom Objects in SuiteCloud Extension for Visual Studio Code
- Importing SDF Custom Objects from a NetSuite Account with SuiteCloud Extension for Visual Studio Code
- Listing Files in SuiteCloud Extension for Visual Studio Code
- Updating a File from Your Account with SuiteCloud Extension for Visual Studio Code
- Uploading Files to Your Account with SuiteCloud Extension for Visual Studio Code
- Importing Files from a NetSuite Account with SuiteCloud Extension for Visual Studio Code
- Comparing a Local File with its Account Version with SuiteCloud Extension for Visual Studio Code
- Adding Dependencies to the Manifest in SuiteCloud Extension for Visual Studio Code
- Validating a SuiteCloud Project Against Your NetSuite Account with SuiteCloud Extension for Visual Studio Code
- Deploying a SuiteCloud Project to Your NetSuite Account with SuiteCloud Extension for Visual Studio Code