Skip to main content
Participating Frequently
November 22, 2023
Answered

Automate/ Contact sheet II. Is there a way to not have the file extension in the captions?

  • November 22, 2023
  • 3 replies
  • 834 views

What it says in the subject!

 

Thanks

 

 

 

 

This topic has been closed for replies.
Correct answer Stephen Marsh

@Brigitte23914987gcbi 

 

Quit Photoshop.

 

Backup the ContactSheetII.jsx file found in your Photoshop application Presets/Scripts directory.

 

Edit the ContactSheetII.jsx file in a plain text editor (if using Apple TextEdit, ensure that it is plain text mode and not rich text).

 

Edit line 6587 which should read as:

 

  self.noExtensions    = false;

 

Change the boolean value:

 

  self.noExtensions    = true;

 

Restart Photoshop and enjoy!

 

A full-featured advanced Contact Sheet X can be found here:

 

https://sourceforge.net/projects/ps-scripts/files/ContactSheetX/v2.2/CSX-2_2.zip/download

3 replies

Stephen Marsh
Community Expert
Community Expert
November 23, 2023

An alternative to editing the ContactSheetII.jsx file is to run a script to remove filename extensions from all text layers:

 

#target photoshop
// Remove filename extension from all text layers

for (var i = 0; i < app.documents.length; i++) {
    app.activeDocument = app.documents[i];
    var doc = app.activeDocument;
    for (var j = 0; j < doc.layers.length; j++) {
        try {
            doc.activeLayer = doc.layers[j];
            if (app.activeDocument.activeLayer.kind == LayerKind.TEXT) {
                doc.activeLayer.textItem.contents = doc.activeLayer.textItem.contents.replace(/\.[^\.]+$/, '');
            }
        } catch (e) {}
    }
}

 

https://prepression.blogspot.com/2017/11/downloading-and-installing-adobe-scripts.html

Stephen Marsh
Community Expert
Stephen MarshCommunity ExpertCorrect answer
Community Expert
November 23, 2023

@Brigitte23914987gcbi 

 

Quit Photoshop.

 

Backup the ContactSheetII.jsx file found in your Photoshop application Presets/Scripts directory.

 

Edit the ContactSheetII.jsx file in a plain text editor (if using Apple TextEdit, ensure that it is plain text mode and not rich text).

 

Edit line 6587 which should read as:

 

  self.noExtensions    = false;

 

Change the boolean value:

 

  self.noExtensions    = true;

 

Restart Photoshop and enjoy!

 

A full-featured advanced Contact Sheet X can be found here:

 

https://sourceforge.net/projects/ps-scripts/files/ContactSheetX/v2.2/CSX-2_2.zip/download

Bojan Živković11378569
Community Expert
Community Expert
November 23, 2023

If you use Bridge > Output tab or workspace, you can omit the file extension by unchecking the option Include File Extension in the Document section of the Output panel.