Skip to main content
brian_alv
Participating Frequently
June 3, 2020
Answered

Does anyone know the name for the "object select tool" in java script to call it from tool pallet

  • June 3, 2020
  • 3 replies
  • 1288 views

Does anyone know the name for the "object select tool" in java script to call it from the tool pallet? I found this reference: https://www.ps-scripts.com/viewtopic.php?f=68&t=11342&p=64930&hilit=selectTool#p64930

 

but it's too old for the object select tool and I can't seem to guess it by naming conventions. I would think it would be "objSelTool" or something like that

 

This topic has been closed for replies.
Correct answer jazz-y

magicLassoTool

3 replies

JJMack
Community Expert
Community Expert
June 3, 2020
selectTool("magicLassoTool");
function selectTool(tool) {
    var desc9 = new ActionDescriptor();
        var ref7 = new ActionReference();
        ref7.putClass( app.stringIDToTypeID(tool) );
    desc9.putReference( app.charIDToTypeID('null'), ref7 );
    executeAction( app.charIDToTypeID('slct'), desc9, DialogModes.NO );
};
/* Some Photoshop tool names here you will not see the Frame tool here I even removed it from my Tool Bar so don't look here
'moveTool'                     'cloneStampTool'            'typeCreateOrEditTool'            'artboardTool'
'marqueeRectTool'              'patternStampTool'          'typeVerticalCreateOrEditTool'    'perspectiveCropTool'
'marqueeEllipTool'             'historyBrushTool'          'typeCreateMaskTool'              'eyedropperTool'              
'marqueeSingleRowTool'         'artBrushTool'              'typeVerticalCreateMaskTool'      '3DMaterialSelectTool'
'marqueeSingleColumnTool'      'eraserTool'                'pathComponentSelectTool'         "magicLassoTool" 
'lassoTool'                    'backgroundEraserTool'      'directSelectTool'
'polySelTool'                  'magicEraserTool'           'rectangleTool'
'magneticLassoTool'            'gradientTool'              'roundedRectangleTool'
'quickSelectTool'              'bucketTool'                'ellipseTool'
'magicWandTool'                'blurTool'                  'polygonTool'
'cropTool'                     'sharpenTool'               'lineTool'
'sliceTool'                    'smudgeTool'                'customShapeTool'
'sliceSelectTool'              'dodgeTool'                 'textAnnotTool'
'spotHealingBrushTool'         'burnInTool'                'soundAnnotTool'
'magicStampTool'               'saturationTool'            'eyedropperTool'
'patchSelection'               'penTool'                   'colorSamplerTool'
'redEyeTool'                   'freeformPenTool'           'rulerTool'
'paintbrushTool'               'addKnotTool'               'handTool'
'pencilTool'                   'deleteKnotTool'            'zoomTool'
'colorReplacementBrushTool'    'convertKnotTool'           'wetBrushTool' 
*/
JJMack
brian_alv
brian_alvAuthor
Participating Frequently
June 4, 2020

Thank you that's an awesoem resource!

 

Chuck Uebele
Community Expert
Community Expert
June 3, 2020

Have you tried using scriptListener to get the code?

brian_alv
brian_alvAuthor
Participating Frequently
June 4, 2020

I just got it working, thank you so much for suggesting it that's awesome!

jazz-yCorrect answer
Legend
June 3, 2020

magicLassoTool

brian_alv
brian_alvAuthor
Participating Frequently
June 4, 2020

Thank you!