I have a scripted search, it works ok. I need to d...
# suitescript
c
I have a scripted search, it works ok. I need to do some parsing of the output, but since I lack for experience I'd like to practice offline. So I'm going over the N/file docs, and I'm trying to figure out how I get the generated output of the search as a file. The example has the following:
Copy code
//Add additional code 
...
var fileObj = file.create({
    name: 'test.txt',
    fileType: file.Type.PLAINTEXT,
    contents: 'Hello World\nHello World',
    description: 'This is a plain text file.',
    encoding: file.Encoding.UTF8,
    folder: 30,
    isOnline: true
});
...
 //Add additional code
Which is all well and good but that has a hard coded value for the file
contents:
is it really just changing the line to the variable that is the search results?