title: Google Apps Scripts: How to save files from root to a specific folder?
body: <p>I'm starting to learn google apps script and suffering a little, :S.</p>
  
  <p>So, when I run this function:</p>
  
  <pre><code>function importXLSX(){
    var files = DriveApp.getFolderById('0B5HXuvZIdqQ3bWlKNXFXZzhIcmc').searchFiles('title contains ".xlsx"');
      while(files.hasNext()){
        var xFile = files.next();
        var name = xFile.getName();
           if (name.indexOf('.xlsx')){ 
              var ID = xFile.getId();
              var xBlob = xFile.getBlob();
              var newFile = { title : name+'_converted',
                   key : ID,
              }
              file = Drive.Files.insert(newFile, xBlob, {
              convert: true
              });
           }
         }
      }
  </code></pre>
  
  <p>The files converteds are set in Drive's root, but I´d like that</p>
  
  <p>When I run the code, the files are saved in the root folder but I would like them to be saved to a specific folder, like "Converteds", so if anyone knows how to solve it, I would be very grateful!</p>
  
  <p>This is a reference link about the function: <a href="https://stackoverflow.com/questions/25368143/convert-all-xls-files-available-in-a-folder-into-google-doc-spreadsheets/44205268#44205268">Convert all xls files available in a folder into &quot;Google Doc Spreadsheets&quot;?</a></p>
  
  <p>Thanks!</p>