Answered
Create a Script for "Install ScriptUI Panel" without having 2 windows.
- October 20, 2022
- 1 reply
- 697 views
Hi all!
This may be a RTFM question, but I can´t find the correct way to use this function.
I made a script (copied below) and when I install it as Install ScriptUI Panel the result is 2 windows, as seen attached, one docable and one not. What am I doing wrong if I want to have only 1 window (the dockable one with the button inside it)
SCRIPT:
var panelRender = this;
var renderWindow = new Window("palette", "Tool", undefined);
var panelRender = renderWindow.add("panel", undefined, "QUEUE");
panelRender.orientation = "row";
var renderButton = panelRender.add("button", undefined, "OPEN APP");
renderButton.onClick = function() {
$.evalFile(File($.fileName).path + '/Tool_v001.jsx')
}
renderWindow.center();
renderWindow.show();
Thanks very much!
Nacho
