Modules
Objects/Functions
SuiteScript 2.0
// Please search https://system.netsuite.com/app/help/helpcenter.nl?search=File.folder for more information.
N/file Module
File.folder
Property Description:
The internal ID of a file’s folder within the NetSuite File Cabinet.
Before you upload a file to the NetSuite File Cabinet with File.save(), you must set its File Cabinet folder with the folder property.
Type:
number | string
Supported Script Types:
Server-side scripts
For more information, see SuiteScript 2.0 Script Types.
Module:
N/file Module
Since:
2015.2
Search NetSuite -
https://system.netsuite.com/app/help/helpcenter.nl?search=File.folder
Example:
// Code Example 1
//Add additional code
//...
var fileObj = file.create({
name: 'test.txt',
fileType: file.Type.PLAINTEXT,
contents: 'Hello World\nHello World'
});
fileObj.folder = 30;
var fileId = fileObj.save();
//...
//Add additional code
//SOURCE: https://system.netsuite.com/app/help/helpcenter.nl?fid=section_4229265810.html