Copy link to clipboard
Copied
Hello,
I am trying to use the Text variable feature in InDesign to bring in the Image Name of the placed PSD. However, I would like it to come in without the suffix.
I was thinking that if there was a way to save the PSD name without the extension, so that when it came into InDesign, that would be missing, but that will not work.
So, then I thought about using a dynamic caption instead of a variable. But I would need a way for the Metadata area of the PSD to have the name somewhere (like description or keywords area), to show the name without the file extension in it.
If anyone has any thoughts, I would greatly appreciate it. I will also be seeking script option, but if there is something within the program that would do this, that would be best,
Thank you,
Babs
Hi Babs:
I'm still following along because I'd like to learn the answer to this question... and guess what! I got it to work!
I used the 3rd link in Stephen Marsh's post: Re: How to Batch copy filename to its metadata Title
Copy link to clipboard
Copied
You could try renaming the file and strip the .psd. I do not install InDesign it may be able to place in a file without and extension it may be able to tell what kind of image file it is be looking at the files metadata. If not if InDesign has a scripting feature you may be able to rename the layer that is placed in. Or look at all layer name and strip know file extensions.
Copy link to clipboard
Copied
Hello JJMack,
I did also attempt something like that, but InDesign still added the extension.. was definitely worth a shot!
thank you!
babs
Copy link to clipboard
Copied
A common enough request Babs!
Here are some Adobe Bridge Scripts which will allow you to batch apply the filename without extension to multiple images:
https://forums.adobe.com/thread/656144 (Filename to Keywords)
CS5 Filename to Title Script | imagesimple​ (Filename to Title)
Re: How to Batch copy filename to its metadata Title (Filename to Title)
Add filename to description​ (Filename to Description)
Prepression: Downloading and Installing Adobe Scripts
If you are comfortable with using the command line, this can also be easily performed using ExifTool.
Copy link to clipboard
Copied
Another option would be to run a script to convert all text variables and or live captions to text, then apply a paragraph style that used a grep style (character) that would remove the extension by colouring it none:
\.[^\.]+$
This would not require you to set the filename to a metadata field, this is a purely InDesign solution.
https://indesignsecrets.com/topic/script-to-convert-all-text-variables
Copy link to clipboard
Copied
Hi Stephen,
Thank you for your reply's...
One of the issues I am having with the Bridge options (I found a really cool one too), is there doesn't seem to be any script area in CC 2018? I have looked in Application Support and in the program, but they have no script options? at least not in the program anymore, from what can see...
I think your second option is what I am really looking for, as I have found a way to use GREP to rename all the Text to remove the file extensions, but would need to convert the variables to text, so I am going to look at your second reply, to try and achieve that.
Thank you so much for all of these!!
Babs
Copy link to clipboard
Copied
Here is a visual of the process that I outlined in post #3:
NOTE: If you use Static Captions rather than Live Captions, then you will not need to convert the Live Caption to text in order to apply the GREP style.
Copy link to clipboard
Copied
Hi Babs:
I'm still following along because I'd like to learn the answer to this question... and guess what! I got it to work!
I used the 3rd link in Stephen Marsh's post: Re: How to Batch copy filename to its metadata Title
Before running script:
After running script:
Now back to InDesign:
~Barb
Copy link to clipboard
Copied
Excellent Barb!
Just a general note (I’m sure the Barb knows this) – any plain text editor will do for saving a script (notepad.exe on Windows or TextEdit.app on Mac). Just ensure that the filename extension is saved as .js or .jsx rather than .txt and check that straight quotes have not become curly.
The nice thing about ESTK is that it has scripting specific features such as syntax highlighting and debug etc… And the filename extension will be correct too!
Babs, my blogpost did cover downloading and installing scripts, it is just as easy as Barb demonstrates above:
http://prepression.blogspot.com/2017/11/downloading-and-installing-adobe-scripts.html
Copy link to clipboard
Copied
WOW~~
You are all amazing! This is terrific!
Going to start testing everything this weekend... There is so much information here, and I am loving it!
I may hicup a little on the script part, it has been awhile... But, I think I have what I need for now...
I can't wait to test this!
MANY MANY MANY THANKS!!!!
babs
Copy link to clipboard
Copied
Hi Stephen,
Thank you so much for sharing your blogpost on installing scripts in all these applications.
very helpful! Working on getting this all to work now!
Cheers!
Babs
Copy link to clipboard
Copied
Hi Barb,
Your graphic is hysterical!! Many days how I feel
I think there is something going on with the 2018 versions... I don't even have the extenscript toolkit available in the apps downloads? But, I do remember them in earlier versions. I have tried to find everything I can on getting the scripts to show up in bridge CC 2018, but nothing seems to be doing anything..
I was able to get the variable to turn into text in InDesign with an AppleScript .. working on getting it to do the entire document not just what page I am on. It is just this right now and is working, then I can do my GREP find and Change and it will work.
tell application "Adobe InDesign CC 2018"
tell application "Adobe InDesign CC 2018"'s document 1 to convert to text text variables
end tell
I really appreciate all the help and sorry it took so long to reply... Just need more computer time
Have a wonderful holiday!!!
Babs