var dp=new DocumentPreset(); dp.artboardSpacing=-20; dp.numArtboards=4; var myDoc=app.documents.addDocument("", dp);