Using a Script in an Action without seeing a dialog box
===================
var doc = activeDocument
doc.resizeCanvas(Math.min(doc.width,doc.height),Math.min(doc.width,doc.height))
===================
I have run the above two line script on individual landscape and portrait photos and it works. It crops the photos to a square using the dimension of the shortest side. No Canvas Size dialog box appears.
However, if I integrate the Script into an Action and start a batch of photos the Canvas Resize dialog box appears needing an OK confirmation for each photo.
Is there anyway I can stop the Canvas Resize dialog box appearing?
Any help would be appreciated. Thanks in advance.
