Hiding a layer with script?

Hello,
is there a way of setting a layer created with a script to hidden? - so that in ae it has that little eye icon turned off.
any suggestions would be sweeet!
thanks, Sam

This will turn off the eye icon:
myLayer.enabled = false;
Dan

Similar Messages

  • Close a layer with scripting

    Hello Adobe Community,
    I would like to know if it is possible to close layer attributes via scripting ?
    Right now I have time-remapping in my script and when the script is done, then the time-remap paramater is shown under the layer.
    I would like to close all the attributes, so that only the layer name is shown.
    Thank You!
    B2H

    It's under: Stuff that makes no sense... To clarify I
    uploaded a quick example:
    embedFont
    First frame has a dynamic textfield, "HelveticaRounded Bold"
    as font family (you can change that to whatever font you are using)
    and 2 lines of code:
    _global.style.setStyle("fontFamily" , "HelveticaRounded
    Bold"); // change the HelveticaRounded Bold to the font embedded in
    the first frame
    _global.style.setStyle("embedFonts" , true);
    The second frame has a button component masked.
    Hope this helps.

  • Create Shape Layer with Script in After Effects

    I wrote a simple script for After Effects and it works well but there is a weird problem.
    My script creates a shape layer which includes group, ellipse path, stroke and fill. Why does the "Group 1" have "Material Options: Group 1" property group? It's empty and it disappers when I click on its eyeball button. I don't want to display the property group. It seems like this problem doesn't happen on CS5.
    Are there any solutions to avoid this? Is this a AE CC bug?
    OS: Windows8.1
    After Effects: version 12.2.1.5
    Here's my script code.
    app.beginUndoGroup("Add new shape layer");
    var curComp = app.project.activeItem;
    if(curComp){ var shapeLayer = curComp.layers.addShape();
    var shapeGroup = shapeLayer.property("Contents").addProperty("ADBE Vector Group");
    shapeGroup.property("Contents").addProperty("ADBE Vector Shape - Ellipse");
    shapeGroup.property("Contents").addProperty("ADBE Vector Graphic - Stroke");
    shapeGroup.property("Contents").addProperty("ADBE Vector Graphic - Fill");
    app.endUndoGroup();

    Just ran a quick test on MAC:
    AE CS3, CS4, CS5 don't produce that Material Options
    AE CS6 & CC have Material Options, but they dissapear once toggle eye icon.

  • Creating an O/R layer with TopLink from Ant or a script

    We're currently using JDeveloper and BC4J to generate an O/R layer that simply creates a BC4J entity for each table in our schema with the appropriate associations between tables. The problem with this approach is that it is very brittle. Any change in the database breaks the BC4J layer and we have to recreate the entire thing. Using the JDeveloper wizzard is labor intensive and we want to automate the task of creating a new O/R layer with a script or Ant task, but unfortunately there is no way to do this with JDeveloper.
    Can we use TopLink to generate an O/R layer using a script or Ant task instead of the workbench? It would be a great time saver for us if we could point TopLink to our schema and have it generate an entity per table with the correct associations without having to use the workbench.
    Thanks.

    I have seen some customers do this, although not necessarily with ANT (it was a while ago). We do ship the Deployment Descriptor DTD (search your TopLink install for *.dtd). That should help you generate the mappings. You're on your own with the code, none of the code gen API's are available on the command line outside the MW.

  • How do i transform a layer with maintain aspect ratio through scripting in Photoshop?

    Hi,
         How do i transform a layer with maintain aspect ratio through scripting in Photoshop? I am expecting your reply.
    thanks,
    Rajiv.s

    I don't think your talking apples to apples.  First I do not know of any Maintain Aspect Ratio icon in Photoshop. The only icon I think associated with transform is the anchor point icon in the option bar for transform. I think you may referring to the constrain check box in the image size dialog which you can check when resample is checked. Image size effect all layers in the document and the documents canvas size. The document canvas size will be changed to the values in the images size dialog and all layers will be transformed by percentage the canvas was changes while maintaining the layers position over the canvas and the layers I think may be cropped so only pixels over the canvas remain.
    I do not know if you know that layers can be any size and have aspect ratios different then the documents canvas.
    In your case it sounds like your describing a template that has a canvas size that is 2000px wide be 3000px high a 2:3 portrait aspect ratio.  Your image file has a landscape aspect. If you place that image into your template place would by default transform the image so the image would fit within the 2000px by 3000px canvas size there would be a white border top and bottom.  You could transform that smart object layer to it actual pixels size activeDocument.activeLayer.resize(100,100, AnchorPosition.MIDDLECENTER); then calculate the size you want to transform its height to. By retrieving the canvas size and the layers boundaries. Divide the canvas height pixel size by the layers pixel height size should give you the percentage you need to use. Make sure you set the ruler units to pixels so your working with pixel values for the canvas and layer size values. The resulting layer will be larger then canvas size keeping the anchor point centered will result in the canvas size masking off both sides.  In effect cropping you landscape to a portrait.  Note cropping a image from one orientation to the other changes the composition drastically.
    If your trying to make a composit like collage you may want to look at my Photoshop Collage Toolkit it will fit images to fill a 2000px by 3000px area http://www.mouseprints.net/old/dpr/PhotoCollageToolkit.html
    You could also do centered 2:3 crop that is resized to a 3000px

  • Help with scripting: need to import Excel files into PS type layers

    Howdy all,
    I have a series of TV commercials provided to me as layered PS files.  I work in CS3 and export to Avid for editing.
    For customization, I need to import their Excel list of phone numbers and duplicate each one into a type layer with existing efx and placement.
    There are 30-60 #s, which appear in 2 locations, so automation is key (just finished a 45 # series, and they have more!)
    I dont know how to script this, and would appreciate any guidance. I am not asking for someone to do it for me, just help me learn what I have to do.
    Dave Koslow

    From Excel save your file out as either CSV or TDT from the drop down 'save as' options. Once you have a plain text file script will be able to read the text file using which ever delimiter best suits you and create an array of string variables that you can use within photoshop to assign to the contents of a text layer…

  • Gradient-Layer with Creative Suite SDK

    Hi,
    i wanna create a gradient-layer with the Creative Suite SDK for AS3. Does anybody have a hint for me, to master this task?

    Have a look at the documentation for the Photoshop Script Listener.
    You'll need to install the script listener, restart Photoshop, create your gradient layer, then convert the script listener output (which is extendscript) to ActionScript.
    Regards

  • Photoshop opens dialog box when trying to fill a layer with transparent pixels locked

    This script should set the layer to lock transparent pixels, and then fill the layer with a color. It does that, except when it gets to the fill stage, it opens the fill dialog box, and you have to hit okay.
    If you omit the transparent pixel line, it runs as expected, no dialog box.
    Is there a way to suppress the box? Or am I doing something wrong that's causing the box to open?
    #target photoshop
    app.bringToFront();
    doc = app.activeDocument;
    doc.artLayers[0].isBackgroundLayer = false;
    doc.artLayers[0].transparentPixelsLocked = true;
    app.activeDocument.selection.fill(app.foregroundColor);

    Not sure why that happens.
    But I would recommend foregoing the locking and using the AM code for a Fill that honours the transparency.
    #target photoshop 
    app.bringToFront(); 
    doc = app.activeDocument; 
    doc.artLayers[0].isBackgroundLayer = false; 
    doc.activeLayer = doc.artLayers[0];
    // =======================================================
    var idFl = charIDToTypeID( "Fl  " );
        var desc18 = new ActionDescriptor();
        var idUsng = charIDToTypeID( "Usng" );
        var idFlCn = charIDToTypeID( "FlCn" );
        var idFrgC = charIDToTypeID( "FrgC" );
        desc18.putEnumerated( idUsng, idFlCn, idFrgC );
        var idOpct = charIDToTypeID( "Opct" );
        var idPrc = charIDToTypeID( "#Prc" );
        desc18.putUnitDouble( idOpct, idPrc, 100.000000 );
        var idMd = charIDToTypeID( "Md  " );
        var idBlnM = charIDToTypeID( "BlnM" );
        var idNrml = charIDToTypeID( "Nrml" );
        desc18.putEnumerated( idMd, idBlnM, idNrml );
        var idPrsT = charIDToTypeID( "PrsT" );
        desc18.putBoolean( idPrsT, true );
    executeAction( idFl, desc18, DialogModes.NO );

  • Problems with script

    hello to all
    i have a little problem with my script
    I ask you if there is the possibility to activate randomize order in a text animator with script
    i have a check box and i try with this function that is
    function make_random(random){
            if(random){
                var animator1 = layer.Text.Animators.addProperty("ADBE Text Animator");
                var selector1 = animator1.Selectors.addProperty("ADBE Text Selector");
                animator1 = animator1.Properties;
                animator1.addProperty("ADBE Text Randomize Order").setValue([on]);
            }else{
    but do not work
    can someone halp me please?
    sorry for my english

    See my reply on your other post:
    http://forums.adobe.com/thread/1312888?tstart=0

  • Photoshop CS6 - How can javaScript fill blank layer with color?

    Hello,
    I'm a production artist and I work with PSD files that were created in Adobe Scene7 Image Authoring Tool. These PSDs contain a background layer along with 1-20 alpha channels. My script has to make new blank layers based on the number of alpha channels and then it has to fill the new layers with light gray. The RGB values are 161, 161, 161. I checked the PSCS6 JavaScript Reference pdf, but I don't see a method that would do this for artLayers. (Let me also say that I'm new to javaScript).
    Does anyone know how to fill a blank layer with these RGB values?
    Here's my script so far:
    #target photoshop 
    // declare variable to contain the active document
    var myDoc=app.activeDocument;
    // declare variable to contain the number of alpha channels, excluding the RGB channels
    var alphaChan = myDoc.channels.length - 3;
    // create loop to make new layers based on number of alpha channels and fill each layer with gray
    for (a=0; a<alphaChan; a=+1){
    myDoc.artLayers.add();
    if (myDoc.artLayers.length == (alphaChan + 1)) {
        break;

    var color = new SolidColor();
    color.rgb.red = 161;
    color.rgb.green = 161;
    color.rgb.blue= 161;
    myDoc.selection.fill(color);

  • How do i take one layer with multiple selections...

    how do i take one layer with multiple selections and make those selections their own layer?

    Yes sir. It w was really hard to explain. It is discontiguous segments that are separated by transparent areas. And I want those non transparent areas to be on their own layer. I have a photo shop file that has a bunch of buttons on them and they are on a transparent background. It is one layer. I want to select all the buttons and put them on their own layers. I can do this manually by selecting a button and cmd Just to a new layer, but when I have 200 buttons it is a daunting task.
    Sent by MailWise<http://www.mail-wise.com/installation/4> – Your emails, with style.

  • How to create a new Oracle OSB project automaticaly with script without IDE

    Hello,
    I want to create automatically an "Oracle service bus project" and an "Oracle service bus configuration project" with scripts (ANT or Maven or ...) without using IDE, without using workshop or Eclipse. I want to create automatically (ANT or Maven) just a skeleton of an OSB project witch i can use after in workshop.
    I want to create 1 "Oracle service bus configuration project" with many "Oracle service bus project" automatically (ANT or Maven or scripts) witch i can use after in workshop. How to create a new Oracle OSB project automaticaly with script without IDE ? How can i do this ?
    I'm using Oracle service bus 10.3.1
    Thank you for your help.

    Thank you for your response,
    I do not want to just create the services (proxy services and business services) but I want to create a template for 40 OSB project with the same scripts ANT/Maven.
    Template="Oracle service bus configuration project" + "Oracle service bus project" + services of 40 OSB projects
    The goal is that I have more than 40 projects to create and just the name of the projects that changes (when I say the name of the project ie the name of the OSB project, the name of proxy services and the name of business services ).
    So I want to give my script (ANT/Maven) the name of 40 OSB project and the script must generate the skeleton of the 40 projects at once time and after generation of skeleton of the 40 project, I will import them in the workshop to add manually mapping and routing and other things that differs from one project to another.
    So i want to generate automatically a skeletons of 40 OSB projects using a script (ANT / Maven) and I give to the script juste the names of the 40 projects.
    I want to create a "Oracle service bus configuration project" and "Oracle service bus project" automatically of 40 OSB projects (ANT or Maven or scripts) witch i can use after in workshop.
    I want to create one 'template' of all 40 projects in the same time, with the same directory structure (Transforlation, Business services, proxy services, WSDL .....) and all 40 project have the same transport, just the names of projects and services witch changes and i can give to the script all names of projects and services and i can give also all WSDL.
    Regards,
    Tarik

  • Hiding Table Columns with the Spry Element Selector

    I am trying to set up a toggle button that will show/hide
    rows >1 when clicked. I've used Adobe's
    "Hiding
    Table Columns with the Spry Element Selector" example and it
    worked fine with an HTML list, until I linked to actual XML data.
    Now it works in reverse. What gives?
    Here's the example:
    http://a44.awardspace.com/testing/toggleShowHideRows.htm

    That's what I started with. Same result:
    http://a44.awardspace.com/testing/toggleShowHideRows.htm

  • If firefox automatically updates my computer past 3.6 I'm inundated with Script Freezes..how do I stop new automatic updates?

    Everytime I'm automatically updated past 3.6 my computer is inundated with Script Freezes..especially on the email page of gmail.
    This has happened many many times. As far as I can determine these Script Freezes (Says: A script is attempting to write on this page.."Continue"..Stop Script etc) are coming from Internet Explorer (I'm not sure of this) and it's tricky to delete any elements of Internet Explorer. But at any rate my computer freezes up until the Script problem is settled..I check the don't ask me again block..but it does no good.
    My real question is: Since things work fine in 3.6...how can I avoid any automatic updates?
    Also, why isn't there a Timer Window (or a timer bar)for Firefox?...sometimes I have to wait 5 minutes for it to load! If there was a timer at least I'd know that something is happening and I'd be willing to wait. When it does take forever to load..it seems to help if I delete all Prefetch and temporary files.
    Is there a safe way of turning off Internet Explorer temporarily?
    Thanks for your help
    Matthew
    [email protected]

    I tried this today, and it is working now:
    Click Firefox > Options > Options > Advanced ... then Uncheck the option "Use hardware acceleration when available"

  • Paragraph Alignment question - is it possible with scripting?

    Hello. I am working on a business card template that has a paragraph alignment problem. I have asked in other forums if it was possible, they pointed out that it might be, with scripting.
    I need to know if it is, so I can dig further.
    Here is the problem: I have a name and title on seperate line that need to be aligned to the right margin (the longest line touches the right margin) but centered above or below themselves. The text box is set to receive a large amount of characters. This is an automated system using InDesign Server so no manual adjustments are being made once the information has been submitted.
    Is this possible?

    Again, I don't know anything about ID Server, but you can try this. Label the text frame 'card' (select the frame, go to Window > Automation > Script label and enter a 'card' -- without the quotes).
    try
       tf = app.activeDocument.textFrames.item ('card');
       p0 = tf.paragraphs[0];
       p1 = tf.paragraphs[1];
       p0.justification = Justification.rightAlign;
       p1.justification = Justification.rightAlign;
       p0left = p0.insertionPoints[0].horizontalOffset;
       p1left = p1.insertionPoints[0].horizontalOffset;
       if (p1left > p0left)
          p1.rightIndent = (p1left-p0left)/2
       else
          p0.rightIndent = (p0left-p1left)/2;
    catch(_){}
    This one doesn't rely on a selection.
    Peter

Maybe you are looking for

  • Can you connect ipod nano to more than one pc wiyh no music loss....help!

    Hi, I have a iPod nano and I would like to know if you can sync the ipod to more than one pc at a time without loosing all the music on it when you connect to another pc i.e I have a pc at work and one at home and would like to us them both with the

  • Can no longer use WEP security on my G3 clamshell

    This morning I updated OS 10.3.9 with the security update that was just released and now I have to disable my WEP security. What happened? My G5 still works fine with my Airport Extreme base station G3 ibook   Mac OS X (10.3.9)  

  • Ipod video screen discoloration?

    im not sure if this is normal or not so im checking. i have a 5g 30g ipod video. when i hold the screen at a slight angle, i see a big rainbow colored spot. when you look head on you dont see it but then if you angle it slightly it catches your eye.

  • STPO Return Process

    Hi All, I am facing a small issue when i am creating return order for stock transfer order. Scenario: 1. I created stock transfer order using ME21N. 2. I created delivery for the same using VL10B, did the picking and PGI 3. I did the commercial invoi

  • HT203167 how to add the music once found

    I am unable to create a new playlist on my ipod classic.  I click on the botton right plu sign and it does nothing.