Hi c.pfaffenbichler, I do not usually use adjustment layers, I have to fix it directly on the selected layer. That was all I could do even though I did not get a way to add the negative value to the image when I move the slider to the left. #target Photoshop var w = new Window ("dialog","Color Balance",[0,0,270,100],); var value = w.add ("edittext {text: 0, characters: 3, justify: 'center', active: true}",[114,10,40,20] ); var cyan=w.add("statictext",[14,38,40,85] ,"Cyan",{multiline:true}); var red=w.add("statictext",[225,38,300,85],"Red",{multiline:true}); var slider = w.add ("slider {minvalue: -50, maxvalue: 150, value: 50}",[43,30,220,50]); slider.onChange= function () { value.text = slider.value - 50 var CR = slider.value; cyan_red(CR); app.refresh(); } /////////////// value.onChange= function () { slider.value = Number (value.text) + 50 } function cyan_red(CR){ /////////////// ///add red ClrB(); function ClrB() { var desc409 = new ActionDescriptor(); var list4 = new ActionList(); var list5 = new ActionList(); var list6 = new ActionList(); list4.putInteger( 0 ); list4.putInteger( 0 ); list4.putInteger( 0 ); desc409.putList( charIDToTypeID( "ShdL" ), list4 ); list5.putInteger( 25 ); list5.putInteger( 0 ); list5.putInteger( 0 ); desc409.putList( charIDToTypeID( "MdtL" ), list5 ); list6.putInteger( 0 ); list6.putInteger( 0 ); list6.putInteger( 0 ); desc409.putList( charIDToTypeID( "HghL" ), list6 ); desc409.putBoolean( charIDToTypeID( "PrsL" ), true ); executeAction( charIDToTypeID( "ClrB" ), desc409, DialogModes.NO ); } /////////////// } w.center(); w.show();
... View more