Export script for .jpg and/or .tif

hi,
i'm quite proficient with java script and action script - now also getting into scripting illustrator. i'd like to write a script to export each layer of an open document as a separate .jpg and/or .tif file.
apparently though, there is no way to access the resolution depth property (i need 300dpi) or the format method property (i need baseline optimized).
can that really be true? only 72dpi output possible? no full property access?
thanks a lot for any hint, maybe there are some strange workarounds?

// http://hicksdesign.co.uk/journal/illustrator-exporting-layers-to-png<br /><br />var document = app.activeDocument;<br />if(document)<br />{     <br />    folder = document.fullName;<br />     var options = new ExportOptionsPNG24();<br />     options.antiAliasing = true;<br />     options.transparency = false;<br />     options.artBoardClipping = false;<br />     <br />     var n = document.layers.length;<br />     for(var i=0; i<n; ++i)<br />     {<br />          hideAllLayers();<br />          var layer = document.layers[i];<br />          layer.visible = true;<br /><br />//          var file = new File(folder.fsName+"-"+layer.name+".png");<br />//          Truncated for MAC<br />          var file = new File(document.path+"/"+layer.name+".png");<br />          <br /><br />          document.exportFile(file,ExportType.PNG24,options);<br />          <br /><br />     }<br />     <br />     showAllLayers();<br />}<br /><br />function hideAllLayers()<br />{<br />     forEach(document.layers, function(layer) {<br />          layer.visible = false;<br />     });<br />}<br /><br />function showAllLayers()<br />{<br />     forEach(document.layers, function(layer) {<br />          layer.visible = true;<br />     });          <br />}<br /><br />function forEach(collection, fn)<br />{<br />     var n = collection.length;<br />     for(var i=0; i<n; ++i)<br />     {<br />          fn(collection[i]);<br />     }<br />}

Similar Messages

  • Shell Script  for Startup and Shutdown the database

    Hi,
    i want Shell Script for Startup and Shutdown the database in Solaries.
    could any one can hep me where i can get this script. or send to me to [email protected]
    Thanks & Regards,
    Gangi reddy

    SHUTDOWN
    SHUTDOWN ABORT]
    Shuts down a currently running Oracle instance, optionally closing and dismounting a database.
    Terms
    Refer to the following list for a description of each term or clause:
    ABORT
    Proceeds with the fastest possible shutdown of the database without waiting for calls to complete or users to disconnect.
    Uncommitted transactions are not rolled back. Client SQL statements currently being processed are terminated. All users currently connected to the database are implicitly disconnected and the next database startup will require instance recovery.
    You must use this option if a background process terminates abnormally.
    IMMEDIATE
    Does not wait for current calls to complete or users to disconnect from the database.
    Further connects are prohibited. The database is closed and dismounted. The instance is shutdown and no instance recovery is required on the next database startup.
    NORMAL
    NORMAL is the default option which waits for users to disconnect from the database.
    Further connects are prohibited. The database is closed and dismounted. The instance is shutdown and no instance recovery is required on the next database startup.
    TRANSACTIONAL [LOCAL]
    Performs a planned shutdown of an instance while allowing active transactions to complete first. It prevents clients from losing work without requiring all users to log off.
    No client can start a new transaction on this instance. Attempting to start a new transaction results in disconnection. After completion of all transactions, any client still connected to the instance is disconnected. Now the instance shuts down just as it would if a SHUTDOWN IMMEDIATE statement was submitted. The next startup of the database will not require any instance recovery procedures.
    The LOCAL mode specifies a transactional shutdown on the local instance only, so that it only waits on local transactions to complete, not all transactions. This is useful, for example, for scheduled outage maintenance.
    Usage
    SHUTDOWN with no arguments is equivalent to SHUTDOWN NORMAL.
    You must be connected to a database as SYSOPER, or SYSDBA. You cannot connect via a multi-threaded server. For more information about connecting to a database, see the CONNECT command earlier in this chapter.
    http://download-west.oracle.com/docs/cd/B10501_01/server.920/a90842/ch13.htm#1013607
    Joel Pérez

  • Need steps to create ant scripts for publishing and deploying projects.

    Need steps to create ant scripts for publishing and deploying projects.
    Have got ant, Oracle BPM Enterprise WL edition installed , Need to know what are the other configurations to be done.
    Any working example would help me to understand, please do mail me at [email protected]
    Thanks in advance.
    -Sree

    Sreekant,
    Please find the build file to publish and deploy.
    <project name="deployProject"
    xmlns:fuego="antlib:fuego.tools.ant.enterprise"
    xmlns:fuego.j2ee="antlib:fuego.tools.ant.j2ee" default = "publish">
              <property file="./Properties/fuego_deploy.properties"/>
              <fuego:passport id="fuego.passport"
    directoryid="${fuego.directoryid}"
    preset="engine" />
    <target name="publish" description="Publish and deploy processes" depends = "takeInputs">
    <!-- Open a session to the Oracle BPM directory -->
    <fuego:session
    passportref="fuego.passport"
    verbose="true"
                   properties="${fuego.basedir}/conf/directory.xml"
    haltonerror="true" >
    <!-- Publish processes -->
    <fuego:publish fpr="${fuego.project.name}"
    deploy="true"
    engine="${fuego.engineName}"
                        importdata = "${fuego.importdata}"
                        automaproles="${fuego.automaproles}"
                        automapbuspars = "${fuego.automapbuspars}"
                        automapvars="${fuego.automapvars}"
                        automapconfigs = "${fuego.automapconfigs}">
    </fuego:publish>
    </fuego:session>
    </target>
    <target name= "takeInputs" >
    <input
    message="Please enter admin-username:"
    addproperty="fuego.participant"
    />
    <input
    message="Please enter admin-password:"
    addproperty="fuego.password"
    >
    </input>
    </target>
    </project>
    and find the properties I have used..
    fuego.basedir=C:\OraBPMEnterpriseHome
    fuego.directoryid=default
    fuego.engineName = bpmengine
    fuego.project.name = E:/antExamples/Project/CommonUtilities
    # If the below property is true then ant script imports data from the project, as defined in Studio.
    # This includes importing:
    #      •Holiday and Calendar rules
    #      •Organizational Units
    #      •Roles
    #      •Resource configurations
    #      •External Variables
    fuego.importdata = true
    #If the below property is true ant script automatically map abstract roles to real ones with the same name.
    fuego.automaproles=true
    #If the below property is true ant script automatically map business parameter variable names (as defined in the project design) to an business parameter variable id with the same name (as defined in the Fuego Enterprise directory).
    fuego.automapbuspars = true
    #If the below property is true ant script automatically map external variable names (as defined in the project design) to an external variable id with the same name (as defined in the Fuego Enterprise directory).
    fuego.automapvars=true
    #If the below property is true ant script automatically map External Resources configurations (as defined in the project design) to real Configurations with the same name (as defined in the Fuego Enterprise directory).
    fuego.automapconfigs = true

  • Location of Camera Raw settings storage for jpg and tiff

    Just upgraded to CS3 on Windows. Cannot figure out where camera raw setting information is stored for jpgs and tiffs, and want to archive settings when I copy the adjusted images to external hard drives. I see no sidecar, and cannot find the info in any other file or folder. David T Cox.

    Since jpg & tiff are documented formats, there's no need for XMP sidecars...the adjustment settings are writtin to the file. Self contained, like DNG.

  • Need training material / test scripts for MRP and Supply Chain module. Can anyone hel

    Can anyone out there provide me with sample test scripts they may have used for upgrading to Oracle Financials 11i? Need sample scripts for MRP and Supply Chain management. Looking for good test scenarios for testing these modules. Appreciate any help. Email at [email protected]

    Can anyone out there provide me with sample test scripts they may have used for upgrading to Oracle 11i? Need sample scripts for MRP and Supply Chain management. Looking for good test scenarios for testing these modules. Appreciate any help. Email at [email protected]

  • Scripts for exp and imp in linux

    please give me some links for exp and imp tables peridical bactch script in oracle 10 R2 over RHEL 4.5.

    user13653962 wrote:
    please give me some links for exp and imp tables peridical bactch script in oracle 10 R2 over RHEL 4.5.try this.. change the same script for your environment
    $ crontab -l
    00 22 * * * sh /u01/db/scripts/testing_user1.sh
    $ cat /u01/db/scripts/testing_user1.sh
    . /home/oracle/TEST1.env
    export ORACLE_SID=TEST1
    export ORA_USER=dbdump
    export ORA_PASSWORD=dbdump
    export TNS_ALIAS=TEST1
    expdp $ORA_USER/$ORA_PASSWORD@$TNS_ALIAS tables=YOUR_tables_NAMEs  dumpfile=TEST_`date +'%Y-%m-%d`.dmp directory=YOUR_DUMPDIR logfile=TEST_`date +'%Y-%m-%d`.logif you need for original export change the exp command,
    exp username/password tables=table_name1,table_name2,etc... file=your_file_name log=your_log_file_name

  • AE Export script for Blender

    I just discovered there is a relatively new AE  script for Blender that exports camera and null data. Add that to the new interface, hard / soft / fluid dynamics and other stuff and Blender is a great resource for AE users.

    hi,
    create a bat file export.bat and schedule it or run it manually
    (give ur oracle home path)
    export.bat
    del d:\expfulldaily.bat
    C:\oracle\product\10.2.0\db_1\BIN\sqlplus scott/tiger @ c:/genexp_script.sql(give the correct path)
    c:/genexp_script.sql
    set linesize 250;
    set pagesize 0;
    set echo off;
    set feedback off;
    set heading off;
    set trimspool on;
    spool D:\expfulldaily.bat;
    select 'c:\oracle\product\10.2.0\db_1\BIN\exp userid=scott/tiger full=y buffer=50000 consistent=y statistics="none" ' || ' file=d:\orcl_' || to_char((sysdate),'dd_mm_yyyy') || '.dmp' || ' log=d:\orcl_' || to_char((sysdate),'dd_mm_yyyy') || '.log' from dual;
    spool off;
    exit;
    to run next time.. you just run the export.bat file... the export it automatically called from genexp_script.sql.. before that it deletes the old entry..
    regards,
    Deepak

  • Shell script for moving and renaming files

    I'm not so familiar with shell scripts. I have created some simple scripts for various tasks but now I hit something I can't handle myself.
    My server receives every night a logfile from another server. This file I need to rename and move to another location. Problem is that a simple mv with new filename isn't enough, I need to insert date in filename. Format for date should be ddmmyy. Also the name of incoming file changes every night. The output always starts with same letters, let's say "log", and the date is used to identify files.
    For example I receive a file /Input/filename.log and I need to move the file to the folder /Output with name log130308.txt.
    Any tips how to insert the date as part of of filename while renaming or moving the file? I prefer shell script as I'll use launchd for scheduling the script.

    Hi again,
    so far I've constructed this:
    cd /input
    for file in `ls *log`
    do
    echo "Copying " $file
    cp $file /output/log.$file.`date +%d%m%y`
    done
    Quite there. I'm cding to directory, i'll focus later how to set some environmental parameters.
    Problem with zipping is that I don't know exact logfiles names. Each day there's a new name. So zip -q filename.zip filename.log isn't quite enough and it's impossible to use wildcards. The switch -q and checksums were welcome suggestions.
    Thanks again,
    Juha
    Message was edited by: J.Otava

  • [SOLVED] advanced shell script for mount and unmount samba share

    Good morning guys,
    Today I've a very long question....
    Hope in your help....:
    I usually move from different network.
    For one of those I need to mount some share that are under an ActiveDirectory server.
    To do that I use samba.
    Especially I've made and use the below  shell script.
    I know that it's so stupid but I'm a very newbie:
    #!/bin/sh
    echo "This is a custom script for mount my citrix share"
    echo "Please insert user password (must a sudoer user)"
    echo " "
    sudo mount -t cifs -o username='myusername',password='mypassword' //host_ip/TsHome$/myusername /home/myuser/samba_share/TsHOME
    sudo mount -t cifs -o username='myusername',password='mypassword' "//host_ip/direction" /home/myuser/samba_share/direction
    echo " "
    read -p "Press ENTER key to close this terminal"
    exit
    As I say the script work but it's so crude...!
    I want/need to implement it whit the follow addictions:
    1. print a feedback on mount: somenthing like "TsHOME is now mounted" or "unable to mount TsHOME"
    2. check if the share are already mounted: to prevent accidentally multiple mount. If a share is already mounted I want to print something like "TsHOME is already mounted on /home/myuser/samba_share/TsHOME"
    3. ask for share password  (now it's in clear on script) - This is optinal
    4. un-mount the share before reboot or shutdown command. That because I've notice that If i reboot or shutdown without manually un-mount the share the step of unmounting network file system became very slow
    If it's no extremely difficult, can someone help me to write this script?
    I know that man exist but I'm not a programmer and it's so difficult for me approch it.
    Thank you in advance.
    Ale
    Last edited by Alexbit (2010-09-23 21:29:13)

    Thank you very (VERY) much!
    I've follow your information and.. it work!
    If can be usefull to other this is the complete script:
    #!/bin/sh
    echo "This is a custom script for mount citrix share"
    echo "****************************************"
    echo " "
    echo "Please insert domain password:"
    read -s mypassword
    echo " "
    echo "|checking mount state...in share are not mounted mount it!|"
    echo "+-------------------------------------------------------------------------+"
    if grep "TsHome" /etc/mtab &>/dev/null; then
    grep "TsHome" /etc/mtab | awk '{print "TsHome is already mounted on " $2}'
    else
    sudo mount -t cifs -o username='yourusername',password="$mypassword" //ipaddress/TsHome$ /home/Samba_share/TsHOME && echo "TsHOME is now mounted" || echo "unable to mount TsHOME"
    fi
    echo " "
    if grep "direction" /etc/mtab &>/dev/null; then
    grep "direction" /etc/mtab | awk '{print "direction is already mounted on " $2}'
    else
    sudo mount -t cifs -o username='yourusername',password="$mypassword" '//ipaddress/direction' /home/Samba_share/direction' && echo "direction pat is now mounted" || echo "unable to mount direction"
    fi
    echo " "
    if grep "Area" /etc/mtab &>/dev/null; then
    grep "Area" /etc/mtab | awk '{print "Area is already mounted on " $2}'
    else
    sudo mount -t cifs -o username='yourusername',password="$mypassword" '//ipaddress/Area' /home/Samba_share/Area && echo "Area is now mounted" || echo "unable to mount Area"
    fi
    echo " "
    echo "All DONE!"
    echo " "
    read -p "Press ENTER key to close this terminal"
    exit
    I don't really well understand what I've to put in rc.local.shutdown....
    I think somethings like:
    #!/bin/bash
    # /etc/rc.local.shutdown: Local shutdown script.
    echo "This is a custom script for UN-mount citrix share"
    echo "********************************************"
    echo " "
    echo "|check mount state: if mount then un-mount!|"
    echo "+-------------------------------------------------------+"
    echo " "
    if grep "TsHome" /etc/mtab &>/dev/null; then
    grep "TsHome" /etc/mtab | awk '{print "TsHome is NOT mounted -> going on..." $2}'
    else
    sudo umount /home/Samba_share/TsHOME && echo "TsHOME is now UN mounted" || echo "unable to UN-mount TsHOME"
    fi
    echo " "
    if grep "direction" /etc/mtab &>/dev/null; then
    grep "direction" /etc/mtab | awk '{print "direction is NOT mounted -> going on.." $2}'
    else
    sudo umount /home/Samba_share/direction && echo "direction is now UN mounted" || echo "unable to UN-mount direction pat"
    fi
    echo " "
    if grep "Area" /etc/mtab &>/dev/null; then
    grep "Area" /etc/mtab | awk '{print "Area is NOT mounted - Finished" $2}'
    else
    sudo umount /home/Samba_share/Area && echo "Area is now UN mounted" || echo "unable to UN-mount Area"
    fi
    echo " "
    echo "going shutdown"
    echo " "
    sleep 5
    I've try but it seems to ignore the IF statement... this is the output when ALL share are UNmounted:
    $ sh /etc/rc.local.shutdown
    This is a custom script for UN-mount citrix share
    |check mount state: if mount then un-mount!|
    +-------------------------------------------------------+
    umount: /home/Samba_share/TsHOME: not mounted
    unable to UN-mount TsHOME
    umount: /home/Samba_share/direction: not mounted
    unable to UN-mount direction
    umount: /home/Samba_share/Area: not mounted
    unable to UN-mount Area
    going shutdown
    Tomorrow I will test again when I'm at office.
    Meanwhile can you check if I made a macroscopic mistakes?
    Thank you again!
    Last edited by Alexbit (2010-09-23 17:34:49)

  • WLST scripts for deploying and migrating OSB project required

    Hi,
    I need sample/reusable WLST scripts for the following requirements:
    1. deploying OSB project developed on workbench to the remote server.
    2. migrating OSB project from Remote Server A to Remote Server B.
    I know other mechanisms to register an OSB project with the server but appreciate if some one can share the above scripts and associated documentation with me.
    Regards,
    CC

    http://download.oracle.com/docs/cd/E13171_01/alsb/docs21/deploy/config_appx.html
    http://www.oracle.com/technology/sample_code/products/osb/samples/PARAMETERIZE.zip (other samples here : http://www.oracle.com/technology/sample_code/products/osb/index.html )

  • Export current format - JPG and MOV files

    When exporting jpg and mov files in "current format" the mov files will be exported with only 1 second (ca 130kb).
    If I export in "original format" it exports the mov files as they are, but the pictures are "original" and not show the last version.
    Any idea?

    If you dleted them you'll need to use a file recovery application like File Salvage
    Regards
    TD

  • SAP Scripts for Training and Event Mgt

    Dear All
    The Following SAP Script ID
    HR_ALL_BUCHSUPER
    HR_ALL_FIXSUPER
    HR_ALL_STORSUPER
    HR_ALL_VORMSUPER
    HR_TEM_NOTE_DISP
    Usually SAP Script in Training and Event Mgt are connected with Output medium through transaction PP40 but the above mentioned is not there .
    How to locate and get the same linked PP40 .
    Regards
    Raji

    Hi,
      Can you explain your requirement in more detail?
    Regards,
    Azaz Ali.

  • Exporting files for web and print at the same time.

    been searching a while now and no joy with an answer.
    So I want to know 2 things.
    Is there an option on LR to export 2 different extensions at once?
    So a JPG at say 5mb and one at 500k?
    Also would I 'resize to' 1024x768 if I was going to use for web?
    Hope you can help.
    Thanks.

    It is possible to pick a desired file size that is too small for the image's pixel dimensions. Where that line is drawn will depend on the individual image.
    Normally if you are picking a max file size, you are also resizing the file to be smaller, like your 1024x768 example above. This size would easily be under 500 kb.

  • Imovie 09 - exporting options for HD and burning with iDVD

    I hope someone can be of help...here it goes
    I shoot my footage in 1080i and import as Full HD into Imovie 09. I would like to export the movie files in 1080i so that I can burn to bluray in the near future. However, I'm currently stuck with burning to DVDs currently.
    1) Does burning to DVD with movie files that are 1080i present any issues with iDVD? If yes, how should I export from imovie 09 to have the best quality?
    2) If exporting as 1080i, should I use: "Export as movie" or "Export as quicktime"
    3) If "export as quicktime", what are the best settings to use?
    Currently, I'm using "export as movie" with "Full HD" and when I go to burn a disc in iDVD, I have to use "high quality" or "profesional quality" due to a popup that says insufficient space...the result doesn't look good. Would the result be better on DVD if I used 960x540 to export and then used that file to burn to DVD?
    My current workflow take about 6 hours to export as 1080i (for 1.5 hours of footage) and then another 4 hours in iDVD to reencode.
    I know, lots of questions
    Thanks for taking time to read post.

    Hi
    As I get it - iMovie'08 & 09 are meant to produce small YouTune movies.
    Not Full HD
    There is NO version of iDVD that can handle HD or Full HD.
    So I think You can export under Share a fairly good QuickTime movie but then You
    need another tool to get it onto a DVD.
    I would use
    • Roxio Toast™ 10 Pro
    • With Blue-Ray component
    • Blue-Ray burner and disks
    Still You need a
    • Blue-Ray Player to be able to view it (Can't be playebacked on DVD-player OR Mac)
    • PlayStation 3 - has a Blur-Ray player
    I would also prepare my movie in FinalCut Express or Pro. One has to cheque
    that Your format can be handled without any limitations.
    Yours Vildly Guessing Bengt W

  • Validation Script for Dates and General Event Questions

    I have just started using Javascript, and am now using some objects and methods etc. that I did not even know about. It's progressing rather well, now I need to know some Livecycle Designer Basics that I can't seem to answer from my searches.
    Here's what I am trying to do in English:
    I want users to choose a date that they will miss at our Farmers Market. I have the date field on the form - works well.
    I want to validate the entry for:
    The date must be today or in the future
    AND
    The date must be before the closing date
    AND
    The date must be a Saturday
    Here's some script I've written and placed in the Validation Event (I have actually written more for testing out that the results are coming out properly):
    ----- form1.#subform[0].Missdate::validate - (JavaScript, client) ----------------------------------
    var entereddate = this.rawValue;// The date vendor will not attend as entered on the form
    var dentry = new Date(entereddate.slice(0,4),[entereddate.slice(5,7)-1],entereddate.slice(8,10),0,0,0); // month starts at 0!
    var closingdate = "October 04,2008" // closing date of the market
    var today = Date();// today
    (dentry.getDay() = 6);// and attempt to validate that the day = Saturday - nothing happens!
    But now -
    How do I actually validate this - my last statement seems to be ignored. How to I force a 'false' being returned? In Formcalc I simply put a camparison statement here and if it resulted in 'False' validation failed and if it resulted in 'True' it passed - What's the JS equivalent? Or are the variables giving me troubles?
    Maybe I'm putting this in the wrong Event? If so which one should I place it in.
    I want to force the user to enter the correct data - how do I code this - and put in a custom message refering to this. I may even get fancy and ask the user if the next Saturday is what they meant if they enter the incorrect one (this will be a real challenge!)
    I think I'm lacking some basic knowledge here that other posts have assumed. Please refer me to any help pages as well - although I've done extensive searching on this and have not really found a good explanation of Validation - only specific pages that are not basic or general enough for my understanding. Thank!

    In the validation script you have to allow the field's length to be 0, or
    it will not be possible to clear it...

Maybe you are looking for