Someone can help me, for make a script to open a window or somethig, and
open the actions that I want.
Thanks in advance
![Embarrassed :oops:](./images/smilies/icon_redface.gif)
Code: Select all
// thans to txuku for scriptui-2-8pdf ( https://www.google.fr/url?sa=t&rct=j&q=&esrc=s&source=web&cd=5&ved=0ahUKEwjV0Iy1zJjPAhXFFZoKHTLQDJkQFghEMAQ&url=ftp%3A%2F%2Fftp.buerliag.ch%2Fpub%2FDevelopment%2FAdobe%2FInDesign%2FCS6%2Fscriptui-2-8.pdf&usg=AFQjCNHUypu3Whnqdm9tLYgcp9oTzNB6kA&cad=rja)
var w = new Window ('dialog', "Would you like to run any ACTIONS?");
w.orientation = "row";
// IMAGES MUST BE SMALL EXAMPLE: 200px / 200px / 100 dpi
var f = File ("/C/Users/Esperanza/Desktop/SCRIPTS/Chrysanthemum.png")
w.add ("iconbutton", undefined, f ); // a
var f= File ("/C/Users/Esperanza/Desktop/SCRIPTS/Hydrangeas.png")
w.add ("iconbutton", undefined, f ); // b
var f = File ("/C/Users/Esperanza/Desktop/SCRIPTS/Koala.jpg")
w.add ("iconbutton", undefined, f ); // c
var f= File ("/C/Users/Esperanza/Desktop/SCRIPTS/Jellyfish.jpg")
w.add ("iconbutton", undefined, f ); // d
w.show ();
Code: Select all
doAction('LOGO HORIZONTAL', 'LOGOS')
Code: Select all
grp = (w = new Window('dialog', 'Would you like to run any ACTIONS?')).add('group')
for(i = 0; i < (icn = ['Chrysanthemum', 'Hydrangeas', 'Koala', 'Jellyfish']).length; i++) {
eval("(ICN"+i+" = grp.add('iconbutton', undefined, File('~/Desktop/SCRIPTS/' + icn[i] + (i < 2 ? '.png' : '.jpg'))))\
.onClick=function() {for(i = 0; i < 4; i++) if (eval('ICN'+i+'.active')) doAction('LOGO '+(i+1),'LOGOS'), refresh()}")
}
w.add('button', undefined, 'Close').onClick = function() {w.close()}, w.show()