var opt = new ImageCaptureOptions(); opt.resolution = 350; var fileObj=new File("~/Desktop/sampleAI00.png"); if(fileObj){ var rect = [0, 0, 320, 240]; // left, top, right, bottom app.activeDocument.imageCapture(fileObj, rect, opt); }