Action script for batch-opening psd layer files flat? (alt+shift?)

hi
i am daily batch processing with an action script to make flat tiffs from psd layer files, like 10-100 files every couple of days in my workflow.
until now i could not fine a solution to begin the batch processing-action with opening layer files FLAT.
the reason is: i am working with huge files, 5-20GB .psb files, (16bit, ECI-RGB, 50x100cm, 300dpi) and it takes a couple of seconds to open with my pcie-SSD.
that multiplies the time it takes to open 50 of such files. i would gain a lot of time, if photoshop cs6 would not open it with layers, but flat.
there is a workaround i am using daily: (osx) hold alt+shift, then click on the layer file in the finder and cs6 opens it flat.
but that did not work in the action script. it doesnt store the keyboard command alt+shift.
any idea how i could save time and use the alt+shift command in the action script or any other solution please?
thanks
peter

I just tried to record this using ScriptListener, and it didn't record it either.  No indo in the ExtendScript SDK on this either.  I don't think that this is possible at this time.  Maybe someone who know more than I do can find a way.

Similar Messages

  • Script for batch delet redundant layer

    I have thousands files in the different folders, each file has same layer named “Job Info”. Can someone help me to write a script for del this layer folder by folder?
    I expected the script tells me that I have to select a folder, then it can automatically open the files, del “job info” layer then save file, rewrite, close file

    Hi Ashram,
    Sorry, I misunderstood your question. Please try the below.
    var folder = Folder.selectDialog ("Select the root folder");
    var myfiles = [];
    var _layers = ["test1", "test2", "test3"];
    getsubfolderfiles(folder);
    for(var i =0;i<myfiles.length;i++)
            var doc = app.open(myfiles[i],false);
            for(var j=0;j<_layers.length;j++)
                try
                    app.activeDocument.layers.add({name:_layers[j]})
                catch(e){}
            doc.save();
            doc.close();
    function getsubfolderfiles(folder)
        var filelist = folder.getFiles();
        for(var i =0;i<filelist.length;i++)
            if(filelist[i] instanceof Folder)
                getsubfolderfiles (filelist[i]);
            else if(filelist[i] instanceof File)
                if(filelist[i].name.indexOf(".indd") > -1){
                    myfiles.push(filelist[i]);
    Hi HarveyLiu,
    Try this,
    var folder = Folder.selectDialog ("Select the root folder");
    var myfiles = [];
    getsubfolderfiles(folder);
    for(var i =0;i<myfiles.length;i++)
            var doc = app.open(myfiles[i],false);
            try{
                var _layer = doc.layers.item("Job Info");
                _layer.remove();
                var link, image, frame,
                links = doc.links, counter = 0;
                for (var i = links.length-1; i >= 0; i--) {
                    if (links[i].status == LinkStatus.LINK_MISSING) {
                        try {
                            link = links[i];
                            image = link.parent;
                            frame = image.parent;
                            frame.remove();
                            counter++;
                        catch (err) {
                            $.writeln(i + " - " + err);
            catch(e){}
            doc.save();
            doc.close();
    function getsubfolderfiles(folder)
        var filelist = folder.getFiles();
        for(var i =0;i<filelist.length;i++)
            if(filelist[i] instanceof Folder)
                getsubfolderfiles (filelist[i]);
            else if(filelist[i] instanceof File)
                if(filelist[i].name.indexOf(".indd") > -1){
                    myfiles.push(filelist[i]);
    Regards,
    Chinna

  • Need script for batch Open/Flatten/Outline/Print Preset/Close/Repeat

    I have an Action created that I use in batch mode on deadline day to flatten my artwork, convert text to outlines, print to our press' desired settings (output to postscript file then distilled from there), then close without saving.
    The problem is even tho tho the Action has a step for the desired print preset, I still have to use the dropbox and select it, then click Print to get the action going again- if I take out the icon where it stops the script to wait for my input, then I get a "Can't print the illustration.  The Color Mangement settings are inconsistent"  error.    So I use the dialog icon to use the drop down to select my desired printer.
    From there the action has a 'Close' step where I get a question asking me to Yes or No to save the file.   I want to always answer No to the question as I want to preserve the file from being flattened and outlined- I just want the copy to be.    The action will not save the No answer to that question.
    This forces me be at the computer and select the printer, click the print button, then answer 'No' for ever file in the batch.   I have to do this for a few hundred files-  its a process that takes over an hour. 
    I think I need a script or some help with the Action so I can get up from the chair and walk away while it does it for me.  I've posted here before years ago but got no response.  I've been dealing with what I have.
    PC, Latest version of IllustratorCC2014
    I'm willing to pay for someone to write a script. 

    I'll PM you to try to help you.   Sorry you had to wait so long for a reply.

  • Shell script for batch compilation of forms 10g on AIX 5.3L AS

    Hi All,
    Can anybody provide me the Shell script for batch compilation of forms 10g and reports 10g on AIX 5.3L AS?
    Regards,
    SAM

    Hi Alex,
    I tried with the below script as well as the one you had posted.
    ORACLE_HOME=/opt/oracle/OraHome_3
    export ORACLE_HOME
    TNS_ADMIN=$ORACLE_HOME/network/admin
    export TNS_ADMIN
    LIBPATH=$ORACLE_HOME/lib32:$ORACLE_HOME/jdk/jre/bin:$ORACLE_HOME/jdk/jre/bin/cla
    ssic:$LIBPATH
    export LIBPATH
    cd ../forms
    for i in `ls *.pll`
    do
    echo Compiling Library $i ....
    $ORACLE_HOME/bin/frmcmp module=$i userid=mydbuser/mydbuser@mydb
    batch=yes module_type=library
    compile_all=yes window_state=minimize
    done
    export ORACLE_HOME=/opt/oracle/OraHome_3
    export ORACLE_TERM=vt220
    export LD_LIBRARY_PATH=/opt/oracle/OraHome_3/lib:/opt/oracle/OraHome_3/jdk/jre/l
    ib:/opt/oracle/OraHome_3/jdk/jre/lib/i386:
    cd ../forms
    for i in `ls *.pll`
    do
    echo "Compiling Library $i ...."
    /opt/oracle/OraHome_3/bin/frmcmp module_type=form userid=mydbuser/mydbuser@mydb
    module=$i batch=yes compile_all=no
    window_state=minimize upgrade=no
    done
    echo "PLL Compilation done"
    But there was a same kind of error thst turning up all the time.
    Compiling Library Agf.pll ....
    Forms 10.1 (Form Compiler) Version 10.1.2.0.2 (Production)
    Forms 10.1 (Form Compiler): Release - Production
    Copyright (c) 1982, 2005, Oracle. All rights reserved.
    Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
    With the Partitioning, OLAP and Data Mining options
    PL/SQL Version 10.1.0.4.2 (Production)
    Oracle Procedure Builder V10.1.2.0.2 - Production
    Oracle Virtual Graphics System Version 10.1.2.0.0 (Production)
    Oracle Multimedia Version 10.1.2.0.2 (Production)
    Oracle Tools Integration Version 10.1.2.0.2 (Production)
    Oracle Tools Common Area Version 10.1.2.0.2
    Oracle CORE 10.1.0.4.0 Production
    FRM-10043: Cannot open file.
    Form not created
    I hence updated the permissions on the pll as below
    -rwxrwxrwx 1 oracle oinstall 335872 May 19 16:31 Agf.pll
    But the problem is still persisting.
    My environment details are as below.
    I am working on Win XP machine. Connected to my AS via telnet and xmanager. I have set my DISPLAY to my local IP.
    Is there any thing more that I need to do? If so then let me know.
    Regards,
    SAM

  • I can no longer open PSD Photoshop files on Preview

    I can no longer open PSD Photoshop files on Preview since I installed Snow Leopard on my White MacBook. Whenever I double click a PSD file, it opens in Photoshop.
    I used to force PSD files to be opened with Preview by "Get Info" (command + I ) and then Changing the option "open with" to Preview.
    I also tried draggin the PSD file onto Preview, nothing happened.
    Did Snow Leopard stop PSD support, or I'm missing something??

    No, I can still open psd files in Preview, no problem, from both Preview's "Open" dialog and by drag 'n drop onto its icon. It opens simple psd files without error, files with an alpha channel may or may not open correctly, layers will display the topmost layer, if that layer has a mask it displays incorrectly. In short, nothing seems to have changed.
    Francine
    Francine
    Schwieder

  • Opening psd video files in premiere elements

    I have Photoshop CS6 and would like to purchase a video editing software.  My question is if I purchase Premiere Elements 12, will I be able to open PSD video files from photoshop in the Premiere Elements?

    Yes. PrE can Import a PSD, so long as it's RGB and 8-bit Color Mode.
    Now, if it is Layered, it will be Flattened upon Import. PrPro can Import a Layered PSD as a Sequence (something that PrE does not have), and maintain those separate Layers.
    The workaround, if you do wish to retain Layers (well, sort of), is to Save each Layer as a separate PSD from Ps, then Import those resultant PSD files, stacking them on successively higher Video Tracks, one above the other.
    Good luck, and hope that this helps.
    Hunt
    PS - I had Moved your post from the Ps General Discussions Forum, before seeing this one. I will Lock that other post, when it shows up, so that if you have any questions, we can continue in this thread - the Adobe Forums are acting up a bit today, and some posts have been very slow to migrate.

  • After action script for Solaris

    Hi,
    I'm having trouble with an after action script for the solaris box.
    my script reads..
    <?xml version='1.0' encoding='UTF-8'?>
    <!DOCTYPE Waveset PUBLIC 'waveset.dtd' 'waveset.dtd'>
    <Waveset>
    <ResourceAction name='after-create'>
    <ResTypeAction restype='Solaris' timeout='60000'>
    <act>
    #!/bin/ksh
    echo "$WSUSER_accountId says Hello World!"
    PATH=/usr/lib/nis:$PATH; export PATH
    nisaddcred -p [email protected] -P keerthi2.example.com. des
    exit 0
    </act>
    </ResTypeAction>
    </ResourceAction>
    </Waveset>
    I have edited the tabbed user form to include the following field:
    <Field name='global.create after action'>
    <Expansion>
    <s>after-create</s>
    </Expansion>
    </Field>
    Now when i am trying to create a user in my IDM n assigning the Solaris resource i'm getting the following error..
    com.waveset.util.WavesetException: An error occurred adding user 'client1' to resource 'Solaris Client'. com.waveset.util.WavesetException: Script failed waiting for "_,)#+(:" in response "" com.waveset.util.WavesetException: Script processor timed out with nothing to read and the following unprocessed text: "".
    the account is created in IDM.
    please help me out!
    Regards
    Sanjeev

    Hi-
    Did you ever get a resolution to this issue? I am seeing the exact same error in IDM 8.0 patch 3
    Error
    com.waveset.util.WavesetException: An error occurred adding user 'testusr15' to resource 'idm_client'. com.waveset.util.WavesetException: Script failed waiting for "$" in response "_,)#+(:" com.waveset.util.WavesetException: Script processor timed out with nothing to read and the following unprocessed text: "_,)#+(:".
    My action script looks like this:
    <?xml version='1.0' encoding='UTF-8'?>
    <!DOCTYPE Waveset PUBLIC 'waveset.dtd' 'waveset.dtd'>
    <Waveset>
    <ResourceAction name='after-create-nppasswd'>
    <ResTypeAction restype='Solaris'>
    <act>
    #!/bin/sh
    touch /tmp/idmtest
    release=`uname -r`
    if [ $release != "5.10" ]; then
         passwd -l $WSUSER_accountId
         sed "s/$WSUSER_accountId:\*LK\*/$WSUSER_accountId:NP/" /etc/shadow > /etc/shadow.new
         mv /etc/shadow.new /etc/shadow
    else
         passwd -N $WSUSER_accountId
    fi
    exit 0
    </act>
    </ResTypeAction>
    </ResourceAction>
    </Waveset>

  • Can I open PSD Video files in premiere elements 12?

    I have Photoshop CS6 and would like to purchase a video editing software.  My question is if I purchase Premiere Elements 12, will I be able to open PSD video files from photoshop in the Premiere Elements?

    Ps CS 6 (and the Extended version back to CS 4) can edit Video (limited Import capabilities, and limited Export capabilities). However, Ps will NOT Export any Video as a PSD. The PSD format is the Ps native Image format, and is output via Save.
    My *assumption* was that the PSD was a Still Image, that was perhaps going to be animated in Video via Keyframing the Fixed Effects, such as Motion>Position, over time, as there is no PSD Video. Perhaps my assumption was incorrect, as to what the OP has, and wishes.
    In Ps CS 6, Video output will be to a standard Video format/CODEC, but the list of available formats/CODEC's is very limited, compared to Premiere.
    Maybe I am just misunderstanding what the OP is looking to do?
    Hunt

  • Script for Batch Exporting XML from IDCS3 files

    Does anyone have a script they would share for batch exporting XML from IDCS3 files? I do not know anything about scripting so I do not know how to write one myself. I've also searched around and cannot find anything. I would appreciate any help with this anyone can offer.
    Thanks,
    Janine

    Or use below Code:
    try {
         inFolderName= Folder.selectDialog ("Input Folder:");
         outFolderName= Folder.selectDialog ("Output Folder:");
         if ((inFolderName != null) && (outFolderName != null))
              var idFileFolder = new Folder(inFolderName);
              var files = idFileFolder.getFiles("*.indd");
              for(myCounter = 0; myCounter < files.length; myCounter++)
                   var theDocument = app.open(File(files[myCounter]));
                   with ( theDocument ) {
                   myXMLFile = new File(outFolderName + "/" + name.replace(".indd","") + ".xml" );
                   exportFile( ExportFormat.xml, myXMLFile );
                   close(SaveOptions.no);
    catch (err ) {
    alert("All files export");
    Shonky

  • Automate Batch, open every 3 files in a folder?

    I'm doing some work where I mostly do the same things on three files. It's for a game-project and I've got one texture for shadows, one that's the normal diffuse layer and finally one that controls where team-colors go. I've learnt some things about the Actions-tab and can easily open all three files then click F2 and Photosohp CS4 does all the work. Then I simply save the file.
    I was checking with the the Automate -> Batch option if I could do this for an entire folder but I've ran out of luck. It's easy enough with the destination, I just add a prefix to the file-name so it doesn't overwrite anything. However as I see it it's only possible to open every file in the folder after each-other. Is there a built-in feature or can I change the Actions a little to help me with this? The Actions I'm doing is mostly "Select Previous Document" etc. when I've got all three files open.
    Failing in that is there a plugin or something anyone can recommend? If it helps the file-names are identical except for a "_diffuse", "_occulusion" and "_team" at the end so if there's a plugin or even feature that relies on the file-names that would work too. Otherwise this also means the three files are always after each-other in the same order.

    You should look into Scripting for Photoshop (preferably with JavaScript), because what you are describing is not within reach for plain Actions as they can incorporate no conditionals.
    »Adobe Intro To Scripting.pdf«, »Photoshop CS5 Scripting Guide.pdf« and the Sample Scripts (should all have been installed with Photoshop) offer a starting point and one can always ask for advice on the Photoshop Scripting Forum:
    Photoshop Scripting
    What exactly are the automated steps for the three different »types« of images?

  • Script for batch processing

    Hello
    I need help
    I created a batch sequence which set watermark and security to pdf files from one directory. Now i want to create another sequence: 1. set security to none and 2. delete watermark.
    I have a problem with set security to none because every time i need change preferences for batch process to security method=password security by hand.
    Maybe there is a way to change this settings with java script in batch "execute java script"?
    Or how i can change with batch sequence a security method from passsword security to "none" if i know password
    Thanks in advance

    Create a "blank" batch process (ie, without any action), but under the Output Options tick the box to optimize the files and set the optimization settings you want to use.

  • I need an action/script for image resizing with a "special" attribute

    Having a headache, nothing work so far the way I want it...
    So here's the deal: I have a bunch of psd files and I need them saved as jpegs in a fixed size - 450x590px.
    The filename of the jpeg should be the same as each psd and the images should be resized proportionate.
    The psds have irregular sizes, some are tall, some are square, some are wide, etc.
    I tried using the place function on a template, but that requires my input - choose what to place, then type the filename.
    Any ideas?
    Thank you for your input!

    elmoldovano wrote:
    So here's the deal: I have a bunch of psd files and I need them saved as jpegs in a fixed size - 450x590px.
    The filename of the jpeg should be the same as each psd and the images should be resized proportionate.
    The psds have irregular sizes, some are tall, some are square, some are wide, etc.
    I tried using the place function on a template, but that requires my input - choose what to place, then type the filename.
    So have both Portrait and Landscape images with varying size. and want to create jpeg from them that are 450x590 pixels in size.  Can the have Portrait and Landscape orientations.  If they all must be Portraits 450px wide by 590px high  your landscape images composition will not fair well.  For cropping landscape image to portraits image normally crops away  to much image content.   Content aware scale may work somewhat better then cropping to portrait the introduced distortion may be acceptable.
    If Portrait 450x590px and Landscape 590x450px is an acceptable solution.  I would go with a cropping solution for there will be no distortion and centered crop composition are usually acceptable.   It can also be done with a two step action used by an image processor script.  If you download my crafting action package. It has a plug-in script that can be recorded in an action to set a 45:59 centered aspect ratio selection which you follow with an Image Crop step.  You run the Image Processor  script have the action make the crop and the Image processor to resize the crop to fit into a 590x590px area.
    Crafting Actions Package UPDATED Aug 14, 2012 Changed AspectRatioSelection Plug-in script added Path support.
    Contains
    Action Actions Palette Tips.txt
    Action Creation Guidelines.txt
    Action Dealing with Image Size.txt
    Action Enhanced via Scripted Photoshop Functions.txt
    CraftedActions.atn Sample Action set includes an example Watermarking action
    Sample Actions.txt Photoshop CraftedActions set saved as a text file.
    12 Scripts for actions
    Example
    Download

  • Conditional Actions Script for PS CS2

    This script from Sivaratnam Gunaratnam will perform actions on Photoshop files and can change depending on certain definable conditions encountered in each file.
    From his Blog entry:
    "This is a tool I scripted for myself that I would like to share with all fellow Photoshopers. It allows you to execute your Actions based on Conditions. No programming needed. Just click and define your conditions.. Some examples of conditions are as follows:
    If the image height is greater than its width, do Action X, or else do else Y
    If the image format is JPG / PSD / BMP do action...
    If the image file size is bigger than 300KB, do action....
    if the image IS/IS NOT of RGB, CMYK... etc
    if image author is Siva, do action...
    if image exif contains Nikon D70s, do action ....
    if image name contains "paris", do action...
    etc
    etc
    Please note thatas of this writinghe has only tested it on Windows and PSCS2. However, someone posted a comment to his blog entry stating that it "Seems to work perfectly on a Mac too."
    caveat downloador :)
    Visit Siva's blog to read more and get the script at the following link:
    http://actionlogic.blogspot.com/2006/03/sivas-photoshop-conditional-action.html

    This script from Sivaratnam Gunaratnam will perform actions on Photoshop files and can change depending on certain definable conditions encountered in each file.
    From his Blog entry:
    "This is a tool I scripted for myself that I would like to share with all fellow Photoshopers. It allows you to execute your Actions based on Conditions. No programming needed. Just click and define your conditions.. Some examples of conditions are as follows:
    If the image height is greater than its width, do Action X, or else do else Y
    If the image format is JPG / PSD / BMP do action...
    If the image file size is bigger than 300KB, do action....
    if the image IS/IS NOT of RGB, CMYK... etc
    if image author is Siva, do action...
    if image exif contains Nikon D70s, do action ....
    if image name contains "paris", do action...
    etc
    etc
    Please note thatas of this writinghe has only tested it on Windows and PSCS2. However, someone posted a comment to his blog entry stating that it "Seems to work perfectly on a Mac too."
    caveat downloador :)
    Visit Siva's blog to read more and get the script at the following link:
    http://actionlogic.blogspot.com/2006/03/sivas-photoshop-conditional-action.html

  • Action Scripting for button

    I created a little 'movie clip' of a continuous animation and
    want to make it a button that can be used in dreamweaver. I was
    told I would have to link it from flash (as dreamweave can not link
    a swf file to a webpage). I was having a problem trying to action
    script the movie clip - when I selected the 'movie clip' graphic it
    said: Current selection can not have actions applied to it. How
    should this be done?
    Thanks

    you're right - that should work. my first thing that i test
    when something like that happens is that every keyframe in the
    tween contains exactly the same instance. A common problem is that
    the instance name of the clip may be slightly different(eg a space
    somewhere) in different keyframes.
    Rather than looking for the problem, I usually just clear the
    keyframes in the tween and then put them back in. In your case I
    cleared the keyframe on frame 12 on layer "see more" and then
    inserted keyframe(returning it to color: None) and tested the
    movie. The button works fine!
    So then i went back to your original movie to try to find
    what was inconsistent between the two keyframes in 'see more' and
    couldn't find the problem... so anyway, this looks like a situation
    where we may not know the reason for the problem but at least we've
    found the solution...

  • Is Action Script for netStreaming and FLVPlayback component radically different, not interchangeabl?

    Hi.
    I am using NetConnection and NetStream to play back flv in Flash Pro CS5.5, and trying to add cue point to trigger events using Action Script, and to automatically rewind to the start at the end. There is no problem to trigger events via AS when the cue points are embedded, but i am unable to add cue points using AS.
    When i use an FLVPlayback component, there is no problem to add cue points (http://help.adobe.com/en_US/ActionScript/3.0_UsingComponentsAS3/WS5b3ccc516d4fbf351e63e3d1 18a9c65586-7feb.html) and to loop the playback using autoRewind (and fl.video.VideoEvent.AUTO_REWOUND which i got from Nafem at http://forums.adobe.com/thread/857036).
    However, i am failing to use this same code w/a netConnection and netStream, and would appreciate any help.
    thanks.

    Hello,
    Well, I've got some help from another helpful fellow at macscripter.net and I have a working script - albeit a bit more specific (ie, hardcoded extensions to look for) and a different approach.
    Here's the script:
    on adding folder items to thisFolder after receiving addedItems
    repeat with movieFile in addedItems
    set {Nm, Ex} to getName_andExtension(movieFile)
    set movieFilePath to (thisFolder as text) & Nm & ".avi"
    set subtitleFile to (thisFolder as text) & Nm & ".srt"
    if Ex is ".srt" then
    try
    tell application "iFlicks"
    import (movieFilePath as alias) with gui
    end tell
    end try
    else if Ex is ".avi" then
    if my FinderItemExists(subtitleFile) then
    try
    tell application "iFlicks"
    import (movieFilePath as alias) with gui
    end tell
    end try
    end if
    end if
    end repeat
    end adding folder items to
    on getName_andExtension(F)
    set F to F as Unicode text
    set {name:Nm, name extension:Ex} to info for file F without size
    if Ex is missing value then set Ex to ""
    if Ex is not "" then
    set Nm to text 1 thru ((count Nm) - (count Ex) - 1) of Nm
    set Ex to "." & Ex
    end if
    return {Nm, Ex}
    end getName_andExtension
    on FinderItemExists(thePath)
    try
    set thePath to thePath as alias
    on error
    return false
    end try
    return true
    end FinderItemExists

Maybe you are looking for

  • Insert and update query to calculate the opening and closing balance

    create table purchase(productid number(5) ,dateofpurchase date, qty number(5)); create table inventory(invid number(5),productid number(5), idate date,openingqty number(5),closingqty number(5)); Records in inventory: 1,1,'01-jan-2009', 10, 20 2,1,'03

  • Viewing media on my Samsung TV

    Guys, I have a samsung 6-series LED TV. I can connect it to my router wirelessly, no problem there. The problem is that I want to watch my movie and music collection from my iMac. I have Vuze, which it seems to recognise (I didn't know Vuze did this

  • Left column gone in iTunes 9

    Just disappeared. Not sure how. Tried uninstalling then reinstalling but it kept my "settings." Help! I'm sure that there is a simple solution and I'm just blind so I am sorry in advance. Screenshot: http://img138.imageshack.us/img138/2453/itunesw.jp

  • Why is the volume for iTunes occasionally lowering?

    I notice that iTunes' volume seems to lower itself. It will happen randomly and then I have to open up the volume mixer and bring iTunes' volume back up. What is causing this?  At first I thought it was when I was plugging in USB devices because that

  • Virus's on 6630

    I seem to have a virus on my phone, how can i remove it? Can i do this myself?