• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

User input during action

Contributor ,
Nov 05, 2024 Nov 05, 2024

Copy link to clipboard

Copied

Hi,

I did:

https://community.adobe.com/t5/photoshop-ecosystem-discussions/ps-actie-script/m-p/14963777#M837464

 

The next step is to request a variable at the start of the action by means of user input.. in this example the "year": so here 2025.
I want to use this year-variable (2025 ... 2026 etc) in the file name: I want to save each ps month layer (as web) as for example: January-VARIABLE-xxxx.png >> becomes: January-2025-xxxx.png
Saving for Web is clear to me, it's about getting the VARIABLE in the file name... during the action.

 

so: how get user input, a variable (text), that I can use in several steps of the action.

 

I read this below, but do not understand it !! and do not know that's the right way??

https://community.adobe.com/t5/photoshop-ecosystem-discussions/stopping-actions-photoshop-to-allow-u...

 

I have no example yet to show you.

TOPICS
Actions and scripting

Views

278

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Contributor , Nov 13, 2024 Nov 13, 2024

@Stephen_A_Marsh 

Adobe question if problem is solved...

The original question comes from: how do I process "user input".
I want to change the file name to the equivalent of the layer name + an addition.
Apparently that doesn't work with "Save for Web" >> PNG is saved as HTML!!.
After some testing I decided not to save for web, but as regular PNG, because it works well there.
I don't use REAL user input, but put the desired text in a dummy work layer in advance and create (append) a complete file name

...

Votes

Translate

Translate
Adobe
Community Expert ,
Nov 05, 2024 Nov 05, 2024

Copy link to clipboard

Copied

@jan99x 

 

How are your layers currently named?

 

Unfortunately, there is no such thing for Photoshop actions.

 

This requires custom scripting.

 

Or you can select all layers in the layers panel, right-click, and use Export As. Ensure all layers are selected on the left, and use the suffix field, which would add the year to the end of the filename.

 

Photoshop has a "File > Export > Layers to Files" script; however, this script uses a variable prefix, which would be added to the front of the filename.

 

Or perhaps you can include the year or a placeholder such as #### in the layer names, export and then use batch file renaming to change the #### into 2025.

 

P.S. I have an idea/feature request for variable filename tokens to be added to save/export dialogs, you can vote on it here:

 

https://community.adobe.com/t5/photoshop-ecosystem-ideas/add-variable-save-filename-tokens-to-save-e...https://community.adobe.com/t5/photoshop-ecosystem-ideas/add-variable-save-filename-tokens-to-save-e...

 

This would just be a custom text variable, rather than using document width or metadata etc.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Nov 05, 2024 Nov 05, 2024

Copy link to clipboard

Copied

@Stephen_A_Marsh 

I already suspected something like that.
I will study your suggestion!
Thanks for now.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Nov 05, 2024 Nov 05, 2024

Copy link to clipboard

Copied

quote
I already suspected something like that.
I tried your suggestion, but select layers and right click...I don't see an "export" option in this list.??

By @jan99x


What version are you using?

 

Right-click on the name area in the Layers panel, not the thumbnail icon or the "eye" visibility icon.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Nov 05, 2024 Nov 05, 2024

Copy link to clipboard

Copied

CS 6, an old one, but good for me.

layers named: like the name of each month

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Nov 05, 2024 Nov 05, 2024

Copy link to clipboard

Copied

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Nov 05, 2024 Nov 05, 2024

Copy link to clipboard

Copied

@Stephen_A_Marsh 

I wil study this... thanks!

But I also want to weigh its usefulness against the solution of simple manual work (I don't make thousands of calendars over and over again...!)

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Nov 13, 2024 Nov 13, 2024

Copy link to clipboard

Copied

LATEST

@Stephen_A_Marsh 

Adobe question if problem is solved...

The original question comes from: how do I process "user input".
I want to change the file name to the equivalent of the layer name + an addition.
Apparently that doesn't work with "Save for Web" >> PNG is saved as HTML!!.
After some testing I decided not to save for web, but as regular PNG, because it works well there.
I don't use REAL user input, but put the desired text in a dummy work layer in advance and create (append) a complete file name with CTRL-C > CTRL-V.
I am satisfied with that solution. The file size hardly differs from save for web and the color difference is nil.
Greetings, Jan

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines