AppleScript error, I do not understand why its happening

Wrote a script that will convert color im black-and-white photos. I wrote it at home on cs 5.1 and it worked perfectly, but when I got it to work on a version of cs6 there bugged. again the code below works on 5.1, but by operating at work he gets into convertpics() photoshop Manager errors.

It errors on changing the fashion line. When it is running I get the word highlight snd mode "expected end of line, etc., but found identifier." (also), he doesn't seem to like the use of the Document 1 or current document.in the other lines? That's how I / m he writes that the dictionary/synatax has changed. (I couldn't find Ant difference). This is my brain race because for me, there's no scene. Help!

Global picfolder

Global origimages

say application 'Finder '.

the value MyHome to (path to the folder) as string

the value picfolder to MyHome & "Documents: Dark Side:

if (there are (file picfolder)) then

movePics() picfolder) of me

on the other

do new folder at 'Documents' with properties of MyHome & {name: 'Dark Side'}

end if

the value myPath to (path to the folder) as string

end say

-a test to see if the files already exist-

-a test to ensure that the original files are still there-

on movePics() picfolder( )

say application "Adobe InDesign CS5.5.

tell document 1

the value linkList to path of the file of links

Repeat with LinkNumber from 1 to number of linkList

set DocImage to the point linknumber of linkList

say application 'Finder '.

copy file docimage to the file picfolder

end say

end Repeat

end say

convertpics() picfolder) of me

end say

end movePics

on convertpics() picfolder( )

say application "Finder" to set origimages to files of entire contents of the folder picfolder

Repeat with j’ai en origimages

the value oneImage to j’ai as string

say application "Adobe Photoshop CS5.1.

Open file oneImage

change mode of document 1 . to Grayscale

set fname to the name of the document as current string

set myFile to picfolder & fname & "_BW"

Save { active document in file myFile like TIFF BOM with options { }:Mac OS stir:fake image compression of the color profile to the:LZW record alpha:falsechannels save layers:false} adding extension lowercase

Close current document without saving

end say

end Repeat

end convertpics

I tried this part in Photoshop CS6, OSX 10.10.4 and it works well.

say application "Adobe Photoshop CS6.

Open file oneImage

change mode of 1 the document in Grayscale

tell the end

Tags: Photoshop

Similar Questions

  • Get error 1013 - do not understand why, tried to fix it

    I'm still new with flex, and I'm interested in AR and have followed a tutorial online for code - next

    package {}
    import flash.display.Sprite;
    import flash.media.Camera;
    import flash.media.Video;
    import flash.utils.ByteArray;

    Import org.libspark.flartoolkit.core.FLARCode;
    Import org.libspark.flartoolkit.core.param.FLARParam;

    [SWF (width = "648". height = "480". = "30" frameRate. backgroundColor = "#FFFFFF")]

    SerializableAttribute public class FLARdemo extends Sprite
    {
    [Embed (source = "markerone.pat". mimeType = "application/octet-stream")]
    private var model: Class;

    [Embed (source = "camera_para.dat". mimeType = "application/octed-stream")]
    private var params: Class;

    private var fparams:FLARParam;
    private var mpattern:FLARCode;
    private var vid:Video;
    private var: camera;

    public void FLARdemo()
    {
    setupFLAR();
    setpuCamera();
    }

    private function setupFLAR (): void
    {
    fparams = new setupFLAR();
    fparams.loadARParam (new params() as ByteArray);
    mpattern = new FLARCode (16, 16);
    mpattern.loadARPatt (new pattern());
    }
    private function setupCamera (): void
    {
    video = new Video (640, 483);
    Cam = Camera.getCamera ();
    cam.setMode (640, 480, 30);
    vid.attachCamera (cam);
    addChild (vid);
    }
    }
    }

    I get the following errors-

    Gravity and Description path location creation time Id resource
    1013: the private attribute may be used only on class property definitions.    FLARdemo/src/FLARdemo.as 15 1251561648500 104 online
    1013: the private attribute may be used only on class property definitions.    FLARdemo/src/FLARdemo.as 18 1251561648500 105 line
    1013: the private attribute may be used only on class property definitions.    FLARdemo/src/FLARdemo.as 20 1251561648500 106 line
    1013: the private attribute may be used only on class property definitions.    FLARdemo/src/FLARdemo.as line 21 1251561648500 107
    1013: the private attribute may be used only on class property definitions.    FLARdemo/src/FLARdemo.as 108 1251561648500 22 line
    1013: the private attribute may be used only on class property definitions.    FLARdemo/src/FLARdemo.as 23 1251561648500 109 line
    1013: the private attribute may be used only on class property definitions.    FLARdemo/src/FLARdemo.as 31 1251561648500 110 line
    1013: the private attribute may be used only on class property definitions.    FLARdemo/src/FLARdemo.as 38 1251561648500 111 line
    1084: syntax error: expecting rightbracket before leftbrace.    FLARdemo/src/FLARdemo.as line 13 1251561648500 103
    1084: syntax error: expecting rightparen before public.    FLARdemo/src/FLARdemo.as line 12 1251561648500 102

    I tried to find a solution online, but everything that I just said to join my statements I looked over and think they are.

    Please give me advice or a solution.

    Thank you

    You can try project > clean

    If this does not work can you copy/paste your code?

    Babo,

  • I get errors MxTray.exe and can not understand why. This error appears randomly.

    I get errors MxTray.exe and can not understand why. This error appears randomly.

    Hello thunder1948m

    Do a search on the internet suggest that the MxTray.exe could be a malicious virus that contains malicious programs.

    If you are not running currently a virus scanner, you can download Microsoft Security Essentials for free. It offers protection in real time and protects against software viruses, spyware and other malicious software.
    You can download here.

    I hope this helps.

  • Im getting this error code: 80080005 and dt000 but I do not understand why or how he got that way please help?

    Original title: help please if you can

    Im getting this error code: 80080005 and dt000 but I do not understand why or how he got that way please help?

    Hi LesaW,

    ·         Exactly when you receive this error code?

    Microsoft has released a new "Fix it" solution that should automatically solve your problems with Windows Update. Click on the link below and follow the instructions.

    How to reset the Windows Update components?

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

    I hope this helps.

  • Do not understand why "the node fpga Audio IN Terminal is 16-bit signed integer"?

    Hello

    I work with myRIO 1900 for my project of ANC.

    Audio IN of the fpga node gives its type terminal data as integer signed 16-bit. So, finally the exit on the nodes of the fpga is fluctuating between two values - 1 and 1. But I want the actual values of the audio data, I did not understand how to address this problem.

    Audio In on the side of RT gives type of terminal of data such as actual values, but I did not understand why the terminal of Audio In FPGAs is 16-bit integer. ??

    Please help me solve this problem.

    Thank you.

    If your analog range of +/-2.5 V.  32768 then--would be the equivalent of-2.5 V.  32767 would be + 2, 5V.

    If you get + /-1 V, then you should see somewhere between + / 13 107 on the analog input of the number I16.

    Basically, take the n ° I16, divide by 32767, multiply by 2.5.  You will have your analog input in volts.

    I don't know why you thing it's just rounding up to the-1 to + 1.  Something must be wrong with your code or configuration.

  • When I copy something from one page to another, it seems to change text color or background, that I do not understand why he never used to do.

    When I copy something from one page to another, it seems to change text color or background, that I do not understand why he never used to do.

    Whether it's text or only a shape it changes its color to something else when I copy and paste on.

    Do you mean 'page' or 'site '?

    If you copy something from another site, the reason may be, to have different, but all also named colours on each site.

    It would be normal and causes the noticed effect.

  • In the attached VI I do not understand why given domestic business structures are not transferred in the table.

    In the attached VI I do not understand why given domestic business structures are not transferred in the table.

    Thank you.

    The VI has yet InfoCluster.ctl.

    If you don't bring anything in the cluster, you should always pass the cluster via.  You run the same question ' use default if Unwired "as before.  The presence of these "case bundleless" begs the question why you have these States because they do nothing.

  • I do not understand why stop you scrolling effects?

    I do not understand why you have disabled the effects of roll with new sensitive sites! Come on! It is therefore sensitive site or site of Parallax scrolling. LAME.

    I waited long for the sensitive site option and now you paralyze it powerless to do scrolling parallax... I'm shaking his head in disbelief and frustration!

    Re: Effects of scrolling in Muse CC 2015

  • I do not understand how its so hard to buy a license for CS6 without the cloud service.

    I do not understand how its so hard to buy a license for CS6 without the cloud service. I don't need the cloud service or will never use it. How much for CS6 license?

    CS6 full: $700 Standard / $1000 Extended Upgrade: $200 / $400 of CS5 owners only.

    CS6 will never be updated, and Adobe Camera Raw is arrested in 9.1.1.

    With this in mind, contact sales if you still want. Creative Cloud now includes Creative Suite Master Collection and Design Premium features

    800-585-0774.

  • Why can not pay monthly software, well that is enough money in the account. I do not understand why not go to pay each month as we did before.

    Hello, I have a problem with adobe photoshop. for some time cannot pay monthly software, although enough money in the account. I do not understand why not go to pay each month as we did before. Since June adobe never had money on the account, although enough money in the account.

    Hi Tina,

    Please contact support by calling/chat for the billing of related queries.

    Contact the customer service

    * Be sure to stay connected with your Adobe ID before accessing the link above *.

    Kind regards

    Sheena

  • I do not understand why my creation of windows DVD burn only 1% of one of my windows movie maker projects.

    Hello

    I made a video of my Windows Movie Maker project and have tried several times to burn through my Windows DVD Maker with the burning of 7% max.  After that, it gets stuck.  However, my other several attempts were a result of burning of 1% and it stuck.  I've left overnight to see if it was the capacity but the next day it is still 1%.  I did other projects without problem.  It is only with this project.  I don't understand why it won't let me if I used Windows movie maker without problem.  The video was originally in AVI, but I was able to convert a 3GP using dvdvideosoft software. Then only, I have done a project using my Windows Movie Maker.  The full minutes of this project is 90 minutes, while the DVD that I want to burn it holds 150 minutes.  Can you help me?  Tried several things and can not find the solution.  I don't know that there must be a solution.

    What or who persuaded allows you to convert AVI, which is supported by Windows, to 3GP, which is not supported by Windows?

    If you must, convert AVI to WMV format.
    Bypass Windows Movie Maker.
    Add the WMV video in Windows DVD Maker directly.
    Try to burn now.

  • Do not understand why this partition by does not include a function of group

    It's the oradocs

    SELECT name, salary, department_id,

    PERCENTILE_CONT (0.5) INTRA GROUP (ORDER BY salary DESC)

    COURSES (PARTITION BY department_id) "Percentile_Cont."

    PERCENT_RANK()

    COURSES (PARTITION BY department_id ORDER BY salary DESC) "Percent_Rank.

    Employees

    WHERE department_id IN (30, 60)

    ORDER BY last_name, salary, department_id;

    http://docs.Oracle.com/database/121/SQLRF/functions140.htm#i1000909

    I recently moved from analytical functions - the PARTITION OF analytical functions I practised so far have prescribed a group by article.

    I don't understand why it does not include a.

    Any tips?

    There is no need to include a GROUP BY in your query, simply because you use analytical functions.

    The main point of the use of analytic functions is to allow you to perform the aggregation or other lines of reference data without having to group data in the normal sense.  The 'score' window, is what defines the data group that you want to reference without actually the outcome of consolidation.

  • Buid error and I do not understand why

    Hello

    I'm a newbe in Java and I can't build this application. Can someone help me? Thank you

    Bernard

    Building SenderSmsBernard
    C:\Program Research In Motion\BlackBerry JDE 5.0.0\bin\rapc.exe-codename-quiet = com\rim\samples\device\SenderSmsBernard\SenderSmsBernard com\rim\samples\device\SenderSmsBernard\SenderSmsBernard.rapc warnkey = 0 x 52424200; 0 x 52525400; 0 x 52435200 import =... \lib\net_rim_api.jar "C:\Program research in Motion\BlackBerry JDE 5.0.0\samples\com\rim\samples\device\SenderSmsBernard\img\SenderSmsBernard_jde.png" "C:\Program search in Motion\BlackBerry JDE 5.0.0\samples\com\rim\samples\device\SenderSmsBernard\SenderSmsBernard.java".
    C:\Program Research In Motion\BlackBerry JDE 5.0.0\samples\com\rim\samples\device\SenderSmsBernard\SenderSmsBernard.java:34: incompatible types
    found: javax.microedition.io.Connection
    required: javax.microedition.io.file.FileConnection
    fileConnection = Connector.open ("file:///SDCard/testfile.txt");
    ^
    1 error
    Error! : error: failed java compiler: javac - 1.3 source-target 1.3 - g - O-d C:\Users\Bernard\AppData\Local\Temp\rapc_33f1d149.dir - bootc...
    Error while building project

    And my code:

    package com.rim.samples.device.SenderSmsBernard;
    import java. IO;
    import java.io.InputStream;
    import java.io.IOException;
    Import Java.util;
    Javax.microedition.io import. *;
    Import javax.microedition.io.Connector;
    Javax.microedition.io.file import. *;
    Javax.wireless.messaging import. *;
    Net.rim.device.api.io import. *;
    Import net.rim.device.api.io.SharedInputStream;
    Net.rim.device.api.system import. *;
    Net.rim.device.api.ui import. *;
    Net.rim.device.api.ui.component import. *;
    Net.rim.device.api.ui.container import. *;
    Net.rim.device.api.ui.picker import. *;
    SerializableAttribute public class SenderSmsBernard extends Application
    {
    private static final int MAX_PHONE_NUMBER_LENGTH = 32;
    private String addr = "0033610101010";
    private String msg = "this is a test message ';
    private DatagramConnection _dc = null;
    private static String _openString = "sms: / /";
    public private static InputStream inputStream = null;
    private static FileConnection fileConnection = null;
    Public Shared Sub main (String [] args)
    {
    new SenderSmsBernard () .enterEventDispatcher ();
    }
    public SenderSmsBernard()
    {
    try {}

    fileConnection = Connector.open ("file:///SDCard/testfile.txt");
    If (fileConnection.exists ())
    {inputStream = fileConnection.openInputStream () ;}

    _DC = (DatagramConnection) Connector.open (_openString);
    data Byte [] = msg.getBytes ();
    Datagram d = _dc.newDatagram (_dc.getMaximumLength ());
    d.setAddress ("/ /" + ADR + ' "'");
    d.setData (data, 0, data.length);
    _DC. Send (d);
    } catch (IOException e) {}
    System.Exit (0);
    }
    }

    Thanks for your help!

    Everything is good now

    Bernard

  • My games will [some] pogo not download what is very frustrating please help I do not understand why my question will not go through

    Some games do not download its very frustrating when games do not download always appears as an error

    Hi Wilma Peters,.

    ·        What is the exact error that you receive when you try to download the game?

    ·        What browser do you use to play games on Pogo.com?

    I suggest you try the troubleshooting steps on Java for Pogo Support site:

    http://www.Java.com/en/download/help/Pogo.XML?OS=Vista&JRE=6.0

    If you use Internet Explorer as your browser, then try IE optimization by the link provided, follow step 2 and step 4:

    http://Windows.Microsoft.com/en-us/Windows/help/Internet-Explorer/slow-five-tips-to-boost-performance

    Alternatively, you can contact pogo support for more help and information.

    I hope this helps.

    Kind regards

    Sandeep

    Microsoft Answers Support Engineer

  • I get an error "application is not reliable because its digital signature not verified" when downloading Java.

    Original title: java Setup error

    Hi, I installed java that I downloaded from java.com, but I get a msg of error before the start of the download saying "application cannot be trusted because its digital signature not verified." Please help me.in

    ya. I had installed it using the offline installation package :). Thank you.

Maybe you are looking for