Script that ran in CS5 not working in CS6

Anyone, especially newbies, asking for help with Photoshop Scripting and Photoshop Automation - as opposed to those contributing to discussion about an aspect of Photoshop Scripting

Moderators: Tom, Kukurykus

bretlinford

Script that ran in CS5 not working in CS6

Post by bretlinford »

Hi, everyone.

I has a javascript I've been using in CS5 to remove all layer comps.

But, now in CS6 is isn't working. When I run it, I get the error:



Here's the code:

Code: Select all/*
This script deletes all layer comps from an image.
*/

// enable double-clicking from the Macintosh Finder or the Windows Explorer
#target photoshop

// in case we double clicked the file
app.bringToFront();

var theImage = app.activeDocument;

theImage.layercomps.removeAll();


Any thoughts? Thanks!

Professional AI Audio Generation within Adobe Premiere Pro - Download Free Plugin here

Mike Hale

Script that ran in CS5 not working in CS6

Post by Mike Hale »

Typo in codeCode: Select alltheImage.layerComps.removeAll();// note uppercase C
bretlinford

Script that ran in CS5 not working in CS6

Post by bretlinford »

thanks, Mike!