Skip to main content
Max Mugen
Inspiring
April 3, 2022
Answered

Shortcut "lock active layer" ?

  • April 3, 2022
  • 1 reply
  • 752 views

Hello everyone is there a way to lock the current layer with a shortcut ?

I'm aware of the command ctrl + 2 but this is not what I'm looking for.

I'm basically in the process of speeding my workflow and working exclusively with a drawing tablet  and shortcuts.  and I have to say I'm pretty  surprised by the huge amount of basic functions that are not assignable to shortcuts…

so after some research I come here because I don't find any solution  and I guess my only way to go with this would be to run a script and then I sing this script activation to a target with a third-party program right ?

and then you had to learn how to code to  use illustrator

This topic has been closed for replies.
Correct answer CarlosCanto

try this to lock the active (highlighted) layer

activeDocument.activeLayer.locked = true;

 

change to false to unlock it

1 reply

CarlosCanto
Community Expert
CarlosCantoCommunity ExpertCorrect answer
Community Expert
April 4, 2022

try this to lock the active (highlighted) layer

activeDocument.activeLayer.locked = true;

 

change to false to unlock it

Max Mugen
Max MugenAuthor
Inspiring
September 30, 2022

Works like a charm ! 
Thanks again Carlos 🙂

-- maxmugen.com