I am trying this code to copy a Google spreadsheet into a specific folder
var targetFolder = DocsList.createFolder(\"Testing\");
var mainDocBlob = DocsList.g
Below is the code that should work. I'm guessing when you get as a blob it.s defaulting to casting the new file as pdf. In the code below makeCopy is defaulting to making the new file name 'Copy of ...' but this can be set by a string.
var targetFolder = DocsList.createFolder("Testing");
var mainDoc = DocsList.getFileById("docId");
mainDoc.makeCopy().addToFolder(targetFolder);