Questions
Recently active
I bumped into yet another mystery: When I run a script directly in ExtendScript, it interpretes the '\r' as a CRLF. Yet, when I called it via bridgetalk, the '\r' was left as text.This strange behavior exists if I set target to photoshop or not. Can someone tell me why please?Below is the unit test (CS6, Windows 10)- Calling script:#target bridgevar bt = new BridgeTalk; bt.target = 'photoshop'; var myPath = '~/Desktop/testCarriageReturnSubstitution.jsx'; var scriptFile = new File(myPath);var fOpen = scriptFile.open('r');var script = scriptFile.read();$.writeln(script);bt.body =script;bt.send(); - Test script:#target photoshopvar badString = '\rTitle\rCity, State - USA December 2015';var newString = badString.replace('\n', "\n");$.writeln (badString);$.writeln(newString);Result when running directly via ExtendScript:TitleCity, State - USA December 2015Result: undefinedResult when invoked via calling script:Result: true\rTitle\rCity, State - USA &
I am trying to use a keyword into sets of images, each of the images on the set contains in the file name what I want for keyword and an extension.Example,File names: WD111_mainWD111_01WD111_02I want all of them to have on the metadata just WD111.help?!?!
This is my first post to this forum, and first I wish to thank those who provided code snippets to help folks. That also helped me tremendously in getting started with Bridge scripting when documentation was deficient. I have been struggling for days trying to figure out why my script did not update metadata correctly, then narrowed down to some odd behaviors (perhaps it only behaves as I instructed it to do).0. In Bridge, create a template to add common metadata info such as author info, copyright1. In Bridge script: Update metadata of an image - event location, headlines etc.; then2. ApplyMetadataTemplate (append) to the same image to add common fields such as author info and copyright; Result: Fields added in step 1 were wiped out; some fields identified in the template were added (creator, copyright status and usage terms), but some did not make it (creator state/country/email/website). I had expected that metadata added before applyMetadataTemplate/append would be retained, and al
I downloaded Bridge CS6 and I have not been able to use it yet. I am on a MacBook Pro running 10.7.4 and every time I launch Bridge I get the following error:Bridge encountered a problem and is unable to read the cache. Please try purging the central cache in Cache Preferences to correct the situation.When I try to purge the cache Bridge freezes up. If I don't try and purge the cache I am unable to navigate to any folders on my computer and it just hangs. I eventually have to force quit to get out of it. So far Bridge CS6 has been completely unusable.Please help.Thanks.
The following script extracts the style names from a style asl file in photoshop. This code works for photoshop CS2, when run from the ETSK with CS2 selected: // CS2 version x = function () { var file = File(app.path + '/Presets/Styles/buttons.asl'); file.open( 'r' ); file.encoding = 'BINARY'; var stuff = file.read( file.length ); var rx = /null\x00\x00\x00\x02\x00\x00\x00\x00Nm[ ][ ]TEXT\x00\x00.+?\x00\x00/g; var result = stuff.match( rx ); if (result != null) { var msg = ''; for (var i = 0; i < result.length; i++ ) { result = result.replace( /.*Nm[ ][ ]TEXT/g, '' ); result = result.replace( /[\x00-\x1F]/g, '' ); msg += '\n'+result; } alert(msg); } } x(); --------------------- However, the identical code, run from Bridge, using BridgeTalk, will not work. BTW, this is the only code I have that will not work via BridgeTalk. It stumbles on (result != null) and photoshop seizes up. The following code is saved as test.jsx in the StartupScripts folder: // Bridge version Test=
HiIm trying to make a context Menu script that creats several folders once i press it.The problem is, i don't know how to get the current active window path for the creation of the folders. Im currently stuck with an absolute path.Anyone know how i can modify the red line to make it work with the current folder path that bridge is displaying when i press the menu?This is what i have: #target bridge if( BridgeTalk.appName == "bridge" ) { var Ordnerstruktur = new MenuElement( "command", "Ordnerstruktur Erstellen", "-at the end of Thumbnail","uniqueId1"); } Ordnerstruktur.onSelect = function () { var folder1 = Folder("~/desktop/My New Folder");//Check if it exist, if not create it.if(!folder1.exists) folder1.create(); alert("Menü 1 gedrückt");}
Hi, working with Adobe Bridge CC on Windows 10 (javascript) - I am trying to add objects to a newly created collection - how do I go about... ? var myCol = app.createCollection('my new collection'); myCol.add(new Thumbnail(File('/c/folder/pathtomy/file.ai'))); But this doesn't seem to work. I also tried children.push, which didn't work...
When I try to purge the cache in bridge, it takes forever to the point where it stops responding to commands. How do I repair this? I've tried to uninstall and reinstall. but the same things keeps happening.
Hi,I am looking for a bridge script which would autostack thumbnails (not the real files) by two (or three, or four, etc ...) for all the picture files inside a folder.ex:-selecting the 2 first thumbnails (the same picture but with different names), then stacking these 2 first thumbnails-selecting the 2 next thumbnails and stacking these 2 thumbnails- and so on ...PS : don't know if it's important but I work with tiff files on PCThanks in advance to the Scripters community.
I'm looking for a way to automate an Illustrator action. I can do batch out of ILL. But was wondering if the Action can be run on a selection of images out of Bridge?ThanksMax
I intalled PS CS6 yesterday only to find that Btidge does not open. I've searched for answers since then and have yet to find any. I've reinstalled it just to see if that would make a difference, but it hasn't. I'm currently running Windows 7 64bit. Photoshop runs great, the only problem is with Bridge, and apparently I can't get any help from Adobe until tomorrow
Hey Everyone,I work in the tech field and part of my daily workflow is checking hundreds of images to make sure they're "up to spec" - they need to be a certain dimension (say, 500x800px), RGB8, and .JPEG files. Is there a way to automate the "spec check" process, wherein images that aren't up to spec might be flagged in some fashion? Say, a file comes in that's the right dimensions and a JPEG but saved in CMYK space. Maybe the script could give it a 1-star rating whereas the others, that are up to spec, would get 5-star ratings? If anybody can give me a jumping off point as to how I'd start that automation, it would be much appreciated. Thanks!Best,Buster
I am trying to process (resize, rename ) by maintaining the original format PNG of about 10 000 images. All images are organized in one folder with several subfolders. Therefore the source folder for each image needs to be the destination folder to avoid a manual resorting afterwards. So far I tried the option of the script image process and batch, as well as “save for web” and multiple combinations of them all . So far no luck, because either the original file format cannot be maintained, or the destination folder cannot be equal to the source folder. It seems that some combination of those three main components seem to out rule each other…Help please!
Hi,I have a script already that runs through folders based on the filenames on those folders, it populates certain metadata. e.g. PhotographerName&&EventName&&Date&&ID.jpg This is fine for short filenames. However for much longer ones, due to Window' limit on size, I can't do this. However, what if I had a list of files e.g.0001.jpg0002.jpg0003.jpg...9999.jpgCould I have a CSV file with the relevant columns filled in, with the first column being the ID, and then import data based on that?Hopefully this makes sense. I have looked through older posts but all the URLs they point to are now goneThanksJJ
I'm trying to organize files by a certain date, i have all the dates in a csv file, but i need to write the script to rename the undated files. they are in the exact order on the csv to combine with the order on bridge. just need to know how to connect the two#target bridge if( BridgeTalk.appName == "bridge" ) { fileNameToProduct = MenuElement.create("command", "Rename to Product", "at the end of Thumbnail"); } fileNameToProduct.onSelect = function () { renameToProduct(); } function renameToProduct(){ var Path =app.document.presentationPath; var descFile = File.openDialog("Open Product File","CSV File(*.csv):*.csv;"); if(descFile == null) return; descFile.open('r'); var datFile=[]; while(!descFile.eof){ var line = descFile.readln(); if(line.length > 5) datFile.push(line); } descFile.close(); for(var t in datFile){
Hi All,I want to extract metadata from bridge. I have 10000 images and need to get the file size, resolution, width n height and color mode/space.I have lots of scripts by downloading from net. But those weren't providing the resolution and color mode specifically. But these both are important for me.Thanks for your help!Purushoth
I have tried to do this with no luck. This script works great, but how to I make it apply to all sub-folders? Thanks for any suggestions.#target bridge if( BridgeTalk.appName == "bridge" ) { descToTitle = MenuElement.create("command", "Keys to Title", "at the end of Tools");}descToTitle.onSelect = function () { if (ExternalObject.AdobeXMPScript == undefined) ExternalObject.AdobeXMPScript = new ExternalObject("lib:AdobeXMPScript"); var thumb = app.document.selections; for(var s in thumb){ if(thumb.hasMetadata){ var selectedFile = thumb.spec; var myXmpFile = new XMPFile( selectedFile.fsName, XMPConst.UNKNOWN, XMPConst.OPEN_FOR_UPDATE); var myXmp = myXmpFile.getXMP(); var Description = getArrayItems(XMPConst.NS_DC, "keywords"); myXmp.deleteProperty(XMPConst.NS_DC, "title");
Is it possible to run code from the Photoshop listener from Bridge. I am having to use the listener because script goes through is a third party tool and its functions and settings are not exposed (couple hundred lines of listener code). So far with bridge I have found that that its easy enough to ask it to do a single simple thing from bridge but doing more than one line is a lot of work.Is there a way to send a chunk of Phothshop script from bridge?Another option I was thinking, was to have Bridge execute a separate Photoshop script, is that possible....i.e. On button press in bridge run Photoshop script.Sorry for all the questions...I am new to the Adobe scripting model and I have found very little documentation and examples online are very hit and miss.Thank you for any help in advance!
This works in Photoshop and Bridge script (Javascript)var myPath = activeDocument.name;//Tester.PSDthis only works in Photoshop script (JavaScript), but not in Bridge.var ProcessFolder = activeDocument.path//actually stops the script... with no error or warning.How can I get the file's path of the active document in Photoshop through Bridge?Thanks!
Hi,Using a script, how would I go about editing the event IPTC Extension value? To change something in the IPTC Core like the description, it would bexmp.deleteProperty(XMPConst.NS_DC, "description"); xmp.setLocalizedText( XMPConst.NS_DC, "description", null, "x-default", Desc );For title it would bexmp.deleteProperty(XMPConst.NS_DC, "title"); xmp.appendArrayItem(XMPConst.NS_DC, "title", Title, 0, XMPConst.ALIAS_TO_ALT_TEXT); xmp.setQualifier(XMPConst.NS_DC, "title[1]", "http://www.w3.org/XML/1998/namespace", "lang", "x-default");For creator ir would be xmp.deleteProperty(XMPConst.NS_DC, "creator"); xmp.appendArrayItem(XMPConst.NS_DC, "creator", Author, 0, XMPConst.ARRAY_IS_ORDERED); What would it be for event and basically all the other IP
Hi,I have the following code. It edits the metadata of a file and it works as needed, apart from the fact you have to be in the folder of images in order to edit the metadata of those images. What do I need to change in order for me to open up just the parent directory and for the script to go through all the child pages one by one, executing the script? #target bridge if( BridgeTalk.appName == "bridge" ) { var vfRename = new MenuElement( "command", "VF Rename", "at the end of Tools" , "vfRename01" ); } vfRename.onSelect = function () { app.document.deselectAll(); var thumbs = app.document.getSelection("jpg"); for(var a in thumbs){ var f =thumbs.spec; var parts = decodeURI(f.name).replace(/- \d+.jpg$/i,'').split('&&&'); setMetadata( File(f), parts ) } function setMetadata( file, parts ){ var Title = parts[0].toString() + " at " + parts[1].toString() + " by " + parts[2].toString(); var Desc = parts[0].toString() + " at " + parts[1].toString() + " by " + parts[2].toS
Hi,I'm about to create a script to check some tifs and jpgs for the right height and width, resolution and so on. I could get it to work if I see the files in the content panel (looping through the files by app.document.getSelection ...The script needs to check many files in different subfolders (all in one parent folder), so I don't like to use a collection to reveal all files of all subfolders first and then start the script.My plan is to choose the parent folder in the folder panel and the script should loop through each file of each subfolder ...So maybe there's someone who knows a solution for this problem, it would be great!Thanks a lot,Sebastian.
bridge encountered a problem and is unable to read the cache.please try purging the central cache in cache preferences to correct the situation.this I have done but nothing is working in bridge it keep freezing up?
Is it possible to have a script to find multiple images within multiple folders that is on a external hard drive?For instances I have a external hard drive assuming it's for a library of pictures.Inside this hard drive has folders named as below1-10001001-20002001-30003001-4000If I had a perfect csv file for example that calls out for specific pictures for example 2, 10,1500 and 2000 (remember think big, it may be a larger list than this it could be hundreds or thousands of pictures); is there a script that would allow me to find these images and save a copy of them on to my desktop so that way I don't have to hunt for them in the old fashion way? I can read scripts but writing them is a different story.
Hi,I'd like to extract just the titles from a number of photos and then store the titles ready to export to an Excel spreadsheet. How do I write an action to do this repeatedly? Would it be in scripts or batch commands? I use Windows 7 and Bridge & Photoshop CC.All help appreciated.Thanks.Trevor
Remix with Firefly Community Gallery
Thousands of free creations to fall in love with and remix in Firefly.
Already have an account? Login
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.