Open a window

Discussion of Automation, Image Workflow and Raw Image Workflow

Moderators: xbytor, DavideBarranca, Paul MR

MIRYAMM
Posts: 7
Joined: Thu Sep 15, 2016 6:15 pm

Open a window

Postby MIRYAMM » Sat Sep 17, 2016 8:29 pm

Hi all

Someone can help me, for make a script to open a window or somethig, and
open the actions that I want.

Thanks in advance :oops:

User avatar
Kukurykus
Posts: 179
Joined: Mon Jul 25, 2016 12:36 pm

Re: Open a window

Postby Kukurykus » Sat Sep 17, 2016 9:18 pm

win = new Window ('dialog' ); win.show()

doAction('nameOfAction', 'setOfActions')

User avatar
txuku
Posts: 67
Joined: Thu Jan 01, 1970 12:00 am

Re: Open a window

Postby txuku » Sun Sep 18, 2016 9:35 am

Bonjour

You can consult this guide for dialogbox ! :)

MIRYAMM
Posts: 7
Joined: Thu Sep 15, 2016 6:15 pm

Re: Open a window

Postby MIRYAMM » Sun Sep 18, 2016 10:13 am

Thanks a million for the two.

I'm going to make, my script.
I Think, that I will need yours helps..

Best regards ;)

MIRYAMM
Posts: 7
Joined: Thu Sep 15, 2016 6:15 pm

Re: Open a window

Postby MIRYAMM » Sun Sep 18, 2016 3:02 pm

I'm a dummy in scripts.
So, I'm testing codes, that I find, and I'm getting the results I need, and so
is impossible for me, put a code in this script for execute an accion.

I Need (on Click) open an action, for every image.

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 ();
I have this script " thanks Kukurykus "
but I dont know how apply

Code: Select all

doAction('LOGO HORIZONTAL', 'LOGOS')

User avatar
txuku
Posts: 67
Joined: Thu Jan 01, 1970 12:00 am

Re: Open a window

Postby txuku » Sun Sep 18, 2016 3:58 pm

A "iconbutton" search in the forum should give you a lot of results :)

MIRYAMM
Posts: 7
Joined: Thu Sep 15, 2016 6:15 pm

Re: Open a window

Postby MIRYAMM » Mon Sep 19, 2016 11:47 pm

I've seen a lot of scripts, and I can't find , that I need. to adapt to my script
even with the help of scriptui-2-12-e-2017, there isn't reference, at least, I have not been able to see

Please Some help?

Thanks in advance

User avatar
Kukurykus
Posts: 179
Joined: Mon Jul 25, 2016 12:36 pm

Re: Open a window

Postby Kukurykus » Sun Oct 02, 2016 4:25 am

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()
An action and four images:
Attachments
SCRIPTS.rar
(14.43 KiB) Downloaded 184 times


Return to “Automation & Image Workflow”

Who is online

Users browsing this forum: No registered users and 6 guests