Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

217
Vistas
How to select a layer inside another layer in Photoshop with Javascript, and make it visible/invisible

I have a Photoshop layer/smart object named "Culoare". When I double click on it, there is another list of layers/smart objects. I need to be able to make visible/invisible the layers inside the first layer. For example, make "warm white" invisible and "blue" visible.

"Culoare" is the first object I need to make visible or invisible the layers here

My code so far:

var doc = app.activeDocument;
var culoare = doc.layers[5];
doc.activeLayer = culoare;
culoare.visible = false;
about 4 years ago · Juan Pablo Isaza
2 Respuestas
Responde la pregunta

0

I don't know much about photoshop script. But based on your code, it seems that the order of your last two lines should be:

culoare.visible = false; 
doc.activeLayer = culoare;

That is 'culoare' should not be visible before you assign it to the active layer. I dont understand why you would want it to be invisible if you are assigning it to the active layer though.

about 4 years ago · Juan Pablo Isaza Denunciar

0

You're nearly there! You don't need to reference the culoare my the layer number as that may change. You can however, use the current active layer instead:

// Create a reference to the active document
var doc = app.activeDocument;

// Create a variable "culoare" as a reference to the current active layer
var culoare = doc.activeLayer;

// Make culoare visible if it's hidden
// or make culoare hidden if it's visible
culoare.visible = !culoare.visible;
about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda