-
1. Re: Auto Add Author Details
c.pfaffenbichler Nov 28, 2012 4:17 AM (in response to Mattmcquiff)One could automate adding information to the metadata with Scripts, which could be linked to events (like saving) with Script Events Manager.
But what information specifically would you want to store?
-
2. Re: Auto Add Author Details
Mattmcquiff Nov 28, 2012 4:18 AM (in response to c.pfaffenbichler)Literally just the Author under the description header.
-
3. Re: Auto Add Author Details
c.pfaffenbichler Nov 28, 2012 4:21 AM (in response to Mattmcquiff)How is the author defined? By computer or may several persons be working on the same computer?
Should that be added to a growing list with every save or replace the potentially existing author information?
Maybe you should ask over at
http://forums.adobe.com/community/photoshop/photoshop_scripting
-
4. Re: Auto Add Author Details
Mattmcquiff Nov 28, 2012 4:25 AM (in response to c.pfaffenbichler)literally just the person using that computer.
and replace exisiting. looking at the scripting method too.
-
5. Re: Auto Add Author Details
Mattmcquiff Nov 28, 2012 4:28 AM (in response to Mattmcquiff)Scripting is best as I can assign it to a shortcut key but would need to hide the Save and save as function in the menu.
-
6. Re: Auto Add Author Details
c.pfaffenbichler Nov 28, 2012 5:17 AM (in response to Mattmcquiff)would need to hide the Save and save as function in the menu.
I guess you could assign a Script the regular command (command-S) and hide the original commands with Edit > Keyboard Shortcuts.
-
7. Re: Auto Add Author Details
Noel Carboni Nov 28, 2012 8:58 AM (in response to Mattmcquiff)I'm no scripting expert by a longshot, but I have heard of the ability of scripts to be run on file-open. Might be possible on file-save as well.
-Noel
-
8. Re: Auto Add Author Details
Paul Riggott Nov 28, 2012 9:54 AM (in response to Noel Carboni)File open would be ok but save would not as events are after they have occured.
-
9. Re: Auto Add Author Details
Paul Riggott Nov 28, 2012 10:08 AM (in response to Paul Riggott)Here is a script that could be used on file open...
activeDocument.info.author = "Your name here";
-
10. Re: Auto Add Author Details
c.pfaffenbichler Nov 29, 2012 12:00 AM (in response to Paul Riggott)I guess »open« should be convenient with the restriction that this would cause files to appear to be dirty even if the user only openend them and did not actually edit them in any way.
Another option would be to add
app.activeDocument.save()
to Paul’s line and use that to save.
This would not affect saving on closing, though.
-
11. Re: Auto Add Author Details
Mattmcquiff Nov 29, 2012 1:13 AM (in response to c.pfaffenbichler)I got a over at ps-scripts and basically echos the help I have had here.
function saveAS() {
if(!documents.length) return;
activeDocument.info.author = "ME";
try{executeAction( charIDToTypeID('save'), undefined, DialogModes.ALL );}catch(e){}
};
saveAS();
And this works a treat, what are the other tags I can use? I found author can be replaced with source, but what about author title etc.
Also is there a way to manually disable/hide the save and save as from the menus?
-
12. Re: Auto Add Author Details
c.pfaffenbichler Nov 29, 2012 1:18 AM (in response to Mattmcquiff)You should be able to disable the shortcuts with Edit > Keyboard Shortcuts and hide the items in the menu with Edit > Menus.
-
13. Re: Auto Add Author Details
Mattmcquiff Nov 29, 2012 1:42 AM (in response to c.pfaffenbichler)I hoped to do that typically it won't let you disable the save and save as, i suppose for obvious reasons
-
14. Re: Auto Add Author Details
c.pfaffenbichler Nov 29, 2012 1:46 AM (in response to Mattmcquiff)I just tried and had no problems in disabling command-S for »Save«.
-
15. Re: Auto Add Author Details
c.pfaffenbichler Nov 29, 2012 1:53 AM (in response to Mattmcquiff)And this works a treat, what are the other tags I can use?
In ExtendScript Toolkit open the »Object Model Viewer« (Help > Object Model Viewer), select »Adobe Photoshop CS6 Object Library« (by default it’s probably set to »Core JavaScript Classes«) and then »DocumentInfo« from the list of »Classes«.
Under »Properties and Methods« you should get a list of properties you can edit via the DOM.
-
16. Re: Auto Add Author Details
Mattmcquiff Nov 29, 2012 2:24 AM (in response to c.pfaffenbichler)Sorry yes disabling CMD S no problem there, I meant use the littel eye to hide its visibility in the Menu itseld
-
17. Re: Auto Add Author Details
c.pfaffenbichler Nov 29, 2012 2:43 AM (in response to Mattmcquiff)Ah, I admit I hadn’t tried that.
-
18. Re: Auto Add Author Details
Mattmcquiff Nov 29, 2012 5:28 AM (in response to Mattmcquiff)Just notice that the script I posted default to jpg (the original image format) Despite the fact that I have added layers, how can I get it to default to PSD?
-
19. Re: Auto Add Author Details
Paul Riggott Nov 29, 2012 11:22 AM (in response to Mattmcquiff)Like this...
function saveAS() { if(!documents.length) return; activeDocument.info.author = "ME"; if(activeDocument.layers.length > 1){ var desc2 = new ActionDescriptor(); var desc3 = new ActionDescriptor(); desc3.putBoolean( stringIDToTypeID('maximizeCompatibility'), true ); desc2.putObject( charIDToTypeID('As '), charIDToTypeID('Pht3'), desc3 ); try{executeAction( charIDToTypeID('save'), desc2, DialogModes.ALL );}catch(e){} }else{ try{executeAction( charIDToTypeID('save'), undefined, DialogModes.ALL );}catch(e){} } }; saveAS(); -
20. Re: Auto Add Author Details
Mattmcquiff Nov 29, 2012 12:01 PM (in response to Paul Riggott)Fingers crossed that looks to be working!!!
Many Thanks


