Treatment of a folder of images with Applescript

Hello world

I'm having a problem with my Applescript I want to open a folder of images and processes in PS.

The script works fine on a single test whose path image file I hard coded to open it, but after the addition of the section in a loop, I'm not sure I have the right to open each image.

This part of my script is:

the value sourceFolder to "Users: etc: etc." as alias

the value destFolder to "/ Users/etc: etc.

-source files and destination for the images

say application "Finder" to set imageSet for each file in sourceFolder

say application "Adobe Photoshop CS6.

Activate

set of parameters of the ruler units to pixel units

Repeat with j’ai of 1 in (County imageSet)

set currentImg to the point I the imageSet

Open currentImg

....

(the rest of the code to adjust the images)

....

end repeat

tell the end

"The error I get is" Finder has been an error: document file "(filename)" "(folder name) file" (the rest of the path to the file) startup disk does not understand the message 'open'. "when it stops at the command"open currentImg ".

I was wondering if someone could help me with this? Or offer a code that would work?

Would be appreciated, because it's the last thing I have to do to complete the script and that the work is completed.

THX in advance

Marty

Try this.

-The need to use Applescript file paths with colons for Finder

game sourceFolder to "Macintosh HD:Users:etc:etc".

destFolder value to "Macintosh HD:Users:etc:etc"

-source files and destination for the images

say application 'Finder '.

the value imageSet to get each file from the folder sourceFolder

end say


say application 'Finder '.

Repeat with I from 1 to (County of imageSet)

game of currentImg to (point I of imageSet) string # force type path Finder to a string

say application "Adobe Photoshop CS6.

activate

define sovereign of parameters of units to pixel units

Open alias currentImg # for Photoshop, should he force to alias!

#(reste dele de code pour ajuster les images)

end say

end Repeat

end say

HTH,

greenrookie

Tags: Photoshop

Similar Questions

  • Duplicate images with "vcm_s_kf" as their prefix in the pictures folder

    In Vista and now Windows 7, in my pictures (or photos) whenever I have add a new image files are created.

    In Vista and now Windows 7, in my pictures (or photos) whenever I have add an image in the images folder, a new folder is created with two versions of the image are created, one 127 x 160 and the other 270 x 338 pixels, both with vcm_s_kf prefixs in their file names. I guess that these are created for email or download purposes, but the folders that are created just to get in the way, as I have no need of these smaller files, they just take to the top of the disc space and space of folder view.

    Is it possible to disable this action?

    Thank you, Tim

    What is a Sony computer?

    If so, see:

    http://social.answers.Microsoft.com/forums/en-us/vistamedia/thread/89a50671-ECA9-4FD5-9c63-1d68eff17e32

    James Wolf MS - MVP [Multimedia]

  • Multiple images with the same file name no doubt prevent export

    iMac running OS X El Capitan v10.11.6; Photos 1.5

    I'm trying to export approximately 331 images and I get an error report saying that only 169 of the exported images due to the inability to create files for 159 of the images.  Then the report gives me the names of files of the first 100 images for which files were not created.  After looking at many images that would not create a file, I realized that, in any case, there was at least one, if not several, other images with the SAME EXACT FILE name as the image in question.  I can't change the names of files by right click on "info".  I tried to export the images and change the names of files to export using the sequential option and the option of album name - always having exactly the same problem.  I even tried not to export an image at once and change the name of the file individually or no available. Is there a work around that? I desperately need to export those specific images. I am trying to create a photo album for shown to mothers who choose a family with which you want to place their child/ren for adoption. I'm at my wit's end.  The kicker is I'm moving towards trying to export all my pictures, and that's going to be a HUGE problem in course for me, so I really hope that there is a way around this question somewhat simply. I am a hobby photographer and use the computer for businesses and crafts.  I've seen a few posts that included answers referencing "AppleScript" - I have no idea how to do something like that.

    From here on I will DEFINITELY ensure that my Canon continually numbers the names of image files and automatically resets.  For the other photos other than Canon, is possible to rename images during the import of the lot?

    All advice and help will be GREATLY appreciated!

    Finder has the ability to rename files with various models of lot.  Simply select all the files to rename, right-click one of the selected files, choose 'Rename X points... '. ", and then set the options and click on the button"Rename ".

  • Everything by moving the folder to desktop folder photo images, he was arrested, now the images are missing

    I was moving a folder with images of office to image folder in the c drive, during the operation to arrest him. When I check the destination file, find the loss of images. file in office is also absent. is it possible to recover or find the folder of origin with the pictures of the balance

    * original title - during a process of moving stop the operation, give rise to a folder missing from office and loss of the Photos

    Hello

    I suggest try to perform the clean boot and then try to move the pictures and check if it helps:

    http://support.Microsoft.com/kb/929135

    NOTE: When you are finished troubleshooting, make sure that restore you the computer mode normal startup such as suggested in step 7 of the above article.

    It will be useful.

  • Music folder became a folder of images

    In my music folder I have files for the music of my son and for mine. In my case, I have a number of subfolders. Now, Windows seems to think that my main Music subfolder is a folder of images, because instead of 'Play All', he said 'Play Slideshow', and when I click on help it offers help with folders of photos. How can I get that back as a music folder?

    Hello

    Thanks for posting the question. I've surely you will help find a solution on the issue.

    1. are you aware of changes to the computer before the show?

    2. What is the file format of the files inside the folder music?

    3. What is the exact location of the folder music?

    I suggest you perform the steps described in the article:

     

    Method 1:

     

    Change the default program for individual files and check.

    Change programs Windows uses by default

    http://Windows.Microsoft.com/en-us/Windows-Vista/change-which-programs-Windows-uses-by-default

     

    Method 2:

    Restore the system to an earlier point before installing this application.

     

    What is the system restore
    http://Windows.Microsoft.com/en-us/Windows-Vista/what-is-system-restore

    System Restore can return your files system to a point in time before you noticed a problem, without affecting documents, photos, or other personal files. If the system restore does not resolve the problem, you can undo the restore operation and choose a different restore point.

    More information on:


    System Restore: frequently asked questions

    http://Windows.Microsoft.com/en-us/Windows-Vista/system-restore-frequently-asked-questions

    Hope this information helps. Please provide more information about the issue so that we can help you.

  • How can I share 'My images' with the other user accounts on my computer?

    How can I share 'My images' with the other user accounts on my computer?

    where are the 'experts' on these forums adverstised?  I can't get an answer to a simple question.  Does anyone know how to do this?

    Here we are, ok, I'm not an expert, but try this:

    Right click on 'My images' > share > specific people... > select that you want to share this folder with.

    ...

    After that, try to connect by using a different account. If you will not be able to open C:\Users\"FirstUser"\Pictures, you try to extend the network in the left pane of Windows Explorer > expand ComputerName > expand users > expand "FirstUser" > photos

  • No image with customized image of Windows 10 Acer Iconia W510

    I'm trying machines Acer Iconia W510 image with an image of Windows 10 we did. We have already photographed a few tens of individuals. A dozen, however, refuse to take the picture. They are currently on Windows 8. The image on an external hard drive that plug us into the USB port.

    The steps I take to the imaging process are as follows: "Change PC settings"->"update and recovery"-> "recovery"->"Advanced startup" and I click on the button 'Restart now', who sends me to a screen with three options, continue to windows 8.1, troubleshooting, and turn off your PC.

    I select 'Troubleshoot '->' Advanced'-> "Image system recovery"

    The Acer screen appears with "Preparation of the system image recovery" at the bottom. I sign in the administrator account when prompted to choose an account.

    A window appears and scans for images. I selected the "Select a system image" option and then select the correct image of Windows 10.

    Then, I select the only available option for "select the date and time of the system image to restore.

    After that, there is a message that says "for the restoration of this computer, needs of Windows to format the drive that the Windows recovery environment is running on." To continue with the restore, shut down this computer and it boot from a Windows installation disc or a disc repair system, then try the restore again. "At this point, I have no way to continue.

    Even if I plug the USB recovery drive we used, I get the same message. I don't know what the problem is or how to get past. Any help is appreciated!

    Hi Ryan,

    According to the description, you can not install updates and the this issue may occur if one or more of the following conditions are met: 

    1. The Windows Update database is damaged.
    2. Antivirus software is configured to scan the folder % Windir%\SoftwareDistribution.
    3. Service (BITS) Background Intelligent Transfer Service does not receive a content link header.
    4. A required system file is incorrectly registered.

    Try it out below mentioned methods and see if it works for you.

    Method 1

    First of all, I suggest you run Windows update troubleshooting tool to get the problem automatically detected and corrected. This fixit checks the configuration of the Windows Update components and repairs, fixes incorrect Windows Update the locations of data and records of necessary services. For the race, the troubleshooter refer to sub article what can I do if I have problems to install updates.

    Windows Update: FAQ

    Method 2

    I suggest you to check if you are able to access Windows Update services and also make sure that the following services are started. If it is not started, follow the listed below as follows:

    a. press the Windows key + R, type "services.msc" (without the quotes) in the Run dialog box to start, and press enter.

    b. Locate the Windows Update service.

    c. right-click on the Windows Update service and select Properties.

    d. in Startup type, select enable.

    e. click Start under Service status.

    f. click OK.

    g. Repeat steps c to f for the following services :

    CSP & Background Intelligent Transfer Service.

    If these steps do not help to solve the problem, you can proceed to the step below and check.

    Method 3

    If the problem persists I suggest to reset the Windows Update components and for this, try to run the fixit described in the following article. If you already tried the fixit even before that I ask of you rerun the fixit.

    How to reset the Windows Update components?

    http://support.Microsoft.com/kb/971058/en-us#LetMeFixItMyselfAlways

    Keep us.

    Kind regards

  • Can you have folders in you folder of images and the images are visible?

    Can you have records in your image folder and the images still be seen? I have a graphic file with images and they can be seen on the site, however if I insert files in the pictures folder, the images are not displayed, are what I did or is not possible with dreamweaver?

    I.e. graphic > pendants > outdoor shots.

    Inside or the other of the two last records images do not appear on my site!

    Images can be shown no matter where they are in your site. The only downside is that you have a working image link.

    For example, Graphic/Pendants/Exteriors_Shots/myImage.png note underscore in the path. This is because many browsers interpret too much space. This means that your subdirectory should be renamed accordingly.

  • How can I show only images with the tag specific higher in the hierarchy of keywords, not including sublevels?

    I use a lot the hierarchical keywords.  For example, the location of the World/Europe/Austria/Tirol/specific.  I sometimes attribute only a top-level keyword (example: Austria) of an image when I don't know any more details.  How can I show only the images that have the label that I select, but not those with levels of basements for this keyword?  Exactly as the choice in folders view to examine only a folder selected, but not subfolders.  There could be a complicated way to implement a smart collection that includes a keyword, but excludes images with more that this number of keywords, but that could be really intensive work.

    It's easy, but fairly obscure: in the library filter bar, select the keyword column.  Click on the 'Properties' button on the right, and then select display: flat.  Now painfully, scroll through the list and select the desired keyword:

  • Script to sort Images with/without clipping paths?

    I searched for a while and can not find a script that will sort a folder of images in two new folders that contain images with and without masks. Anyone have or know of a script that will do this for me? I'd be very happy. W7, PS CS5 32 and 64 bit.

    Thanks in advance!

    Andy

    Mark has made the work a lot more on what I have and it would be so worth having an eye on them.

    Mark only your layers to find together scripts?

    The script in its present form should find ways of trimming but not group layers.

    I modified the script to split the files into hasClip, hasPath and noPath of three files.

    #target bridge
     if( BridgeTalk.appName == "bridge" ) {
    clipPaths = MenuElement.create("command", "Sort Clipping Paths", "at the end of Tools","clipping");
    }
    clipPaths.onSelect = function () {
    app.document.deselectAll();
    var thumbs = app.document.getSelection("psd, tif, jpg, eps");
    var noPath = new Folder(app.document.presentationPath+ '/noPath');
    var hasPath = new Folder(app.document.presentationPath+ '/hasPath');
    var hasClip = new Folder(app.document.presentationPath+ '/hasClip');
    if(!noPath.exists)  noPath.create();
    if(!hasClip.exists)  hasClip.create();
    if(!hasPath.exists)  hasPath.create();
    for(var a in thumbs){
    var tempFile = thumbs[a].spec;
    var Path = false;
    var Clip = false;
    tempFile.encoding='BINARY';
    tempFile.open('r');
    var str= tempFile.read();
    tempFile.close();
    var pathTag = '8BIM\x07\xd0';
    var clippingPathTag = '8BIM\x0b\xb7';
    var tagPos =str.match(pathTag);
    if(tagPos){
        Path = true;
        tagPos =str.match(clippingPathTag);
        if(tagPos){
            Clip = true;
            }
    }
    str = null;
    if(!Path) thumbs[a].moveTo(noPath);
    if(Path && Clip)  thumbs[a].moveTo(hasClip);
    if(Path && !Clip) thumbs[a].moveTo(hasPath);
    }
    };
    
  • How to perform an action on a folder of images?

    The last time I used Photoshop was in 1998, and things have changed a bit. I don't know if I had the time to read all the documentation, I could figure out how to do this, but I am under a very tight deadline and the guy who would normally do image processing is on vacation.

    I have a file over 500 images. I need to change the height, width and resolution of each of them. I know how to record an action that I can manually run on open images, but is it possible to perform this action on a folder of images without having to open each one? This could take years if I need to open them before performing the action.

    Record that an action do not have a backup in it. After you have this action recorded with no document open in photoshop use menu file > PLC > lot... in the point of dialogue for scripts a whole batch and action, point source to your images folder. In desternation, use drop down the menu and click on save and close.

  • How to make an image with a transparent background?

    I brought a picture of PS in Illustrator and I want to put in AE and use the puppet tool. However, when I bring what it has a white background, but I got everything as the object I'll puppet, so how can I do to?

    AE does not require an image will initially come out by Illy. Just make sure that your image has a transparent background or an alpha channel, if needed, and then save as a psd file. AE take the PSD in images, unless you need a compostion and folder for the psd, created in the project list. You should then be able to use the tool puppet on an image with a transparent background.

  • Whenever I have download an image with the command "save the image under...". ", it records in a useless file of 168 bits.

    As stated, whenever I have download an image with the command "save image under" he recorded in a useless file of 168 bits. This does not happen everytime I have save an image, but more often the not, and I don't have a lot of useless files hang out because of this. Is it possible to re - download each image 168 bits that he should have been downloaded in the first place? Is it possible to ensure that this does not happen?

    Here's what it looks like:
    http://i.imgur.com/yzgwwgC.gif?1

    This means that you are not allowed to do this action.
    The site could use a transparent overlay image to protect the actual image or otherwise has put in place a protection.
    You can check if see you the image in "tools > Page Info > Media ' and save it.

  • Loose-leaf in number with AppleScript

    Is it possible to move a sheet of numbers e.g. move it left or to right or before / after a roadmap or even copy to a location (as in the list of sheets) and delete the original with AppleScript? Thank you.

    you mean likein this article ?

    Jason

  • Right-click on the image with link problem after upgrade to 11.0

    After the upgrade, whenever I do a right-click on an image with a link, it opens the link rather than opening a menu drop-down. Any idea on what is causing this behavior?

    OK, think about it. Extension: Tab Utilities was the origin of the problem. Uninstall completely solved the problem, disable it does not solve it.

Maybe you are looking for

  • Stream HP: locked out

    I had somehow locked out of my computer hp laptop flow. It says enter the password administrator or power on password in blue. When I hit enter 3 times the number that comes up is 55030754. Help, please! Thank you

  • How to remove the redirect of oyodomo in a browser

    There is a malware to redirect fix yourself to web browsers. If you google it or perhapps Bing you will find all kinds of people after being attacked by this what it is. Much of this, try down loading this, our program will cure this. Yet the page re

  • Pregnant wireless Bose SoundLink has been integrated with success but don't connect/play audio via Bluetooth

    Separated from this thread. How did you get your SoundLink Mini system works? I have the same camera, he paired, but does not connect properly.

  • Hibernate in windows 8

    Well well Hello again,. I want an option "hibernate" on my list of... sought judgment on net, I tried these processes, but I did not see a checkbox "Display Hibernate" while doing so... what I need to do?

  • problem of password on updates of the player

    I can't update the player with a download of Adobe as the password (which has been updated in Adobe) has not been accepted... Is there another password Adobe seeks to allow the update of download?