Copy link to clipboard
Copied
Hi, I couldn't find anything in OMV or in the forum on how to remove existing guides in Photoshop. The help is highly appreciated.
Yulia.
Copy link to clipboard
Copied
You have to use scriptlistner to clear the guides
function clearAllGuides() {
var desc = new ActionDescriptor();
var ref = new ActionReference();
ref.putEnumerated( charIDToTypeID( "Gd " ), charIDToTypeID( "Ordn" ), charIDToTypeID( "Al " ) );
desc.putReference( charIDToTypeID( "null" ), ref );
executeAction( charIDToTypeID( "Dlt " ), desc, DialogModes.NO );
}
Copy link to clipboard
Copied
Thank you, Michael, it works perfectly.
Yulia
Copy link to clipboard
Copied
this doesn't work in photoshp cs6 64bit w7
please could you test it and maybe fix it?
thanks
Copy link to clipboard
Copied
That Action Manager function does work in CS6. I don't know why it is not working for you unless you did not add the function call.
Here is a DOM version.
app.activeDocument.guides.removeAll();
Copy link to clipboard
Copied
hi
Copy link to clipboard
Copied
The code in that thread to remove guides is the same as the code I posted. The only difference is I wrapped mine in a function. The function will not work unless called using
clearAllGuides();
Find more inspiration, events, and resources on the new Adobe Community
Explore Now