• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

palette for UI problems

Participant ,
Oct 19, 2021 Oct 19, 2021

Copy link to clipboard

Copied


Hello everyone,
I have a little problem and can't find the fault.
I've put together a few scripts with UI and usually start them via my plugin Configurator Reloaded.
Everything works as it should.


Now I wanted to use a few scripts on another computer and open the scripts directly via Photoshop.

Photoshop either crashes directly or closes the script directly.


Maybe someone has an idea why that could be?

 

I also absolutely need the palette so that I can continue to work in Photoshop in the background and the script can remain open.

 

here is an example:

 

// DIALOG
// ======
var dialog = new Window("palette", undefined, undefined, {closeButton: false});
dialog.text = "ntOpener";
dialog.orientation = "column";
dialog.alignChildren = ["center","top"];
dialog.spacing = 10;
dialog.margins = 16;

// PANEL1
// ======
var panel1 = dialog.add("panel", undefined, undefined, {name: "panel1"});
panel1.orientation = "column";
panel1.alignChildren = ["left","top"];
panel1.spacing = 10;
panel1.margins = 10;

var button1 = panel1.add("button", undefined, undefined, {name: "button1"});
button1.text = "Open in Explorer";

button1.onClick = function(){Folder(activeDocument.path).execute();

}
dialog.show();

TOPICS
Actions and scripting

Views

433

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Guide , Oct 19, 2021 Oct 19, 2021
var bt = new BridgeTalk(); 
bt.target = "photoshop"; 
bt.body = "var palette = " + fn.toString() + "; palette();"
bt.send(); 

function fn () {
// DIALOG
// ======
var dialog = new Window("palette", undefined, undefined, {closeButton: false});
dialog.text = "ntOpener";
dialog.orientation = "column";
dialog.alignChildren = ["center","top"];
dialog.spacing = 10;
dialog.margins = 16;

// PANEL1
// ======
var panel1 = dialog.add("panel", undefined, undefined, {name: "panel1"});
panel1.orientation = 
...

Votes

Translate

Translate
Adobe
Guide ,
Oct 19, 2021 Oct 19, 2021

Copy link to clipboard

Copied

var bt = new BridgeTalk(); 
bt.target = "photoshop"; 
bt.body = "var palette = " + fn.toString() + "; palette();"
bt.send(); 

function fn () {
// DIALOG
// ======
var dialog = new Window("palette", undefined, undefined, {closeButton: false});
dialog.text = "ntOpener";
dialog.orientation = "column";
dialog.alignChildren = ["center","top"];
dialog.spacing = 10;
dialog.margins = 16;

// PANEL1
// ======
var panel1 = dialog.add("panel", undefined, undefined, {name: "panel1"});
panel1.orientation = "column";
panel1.alignChildren = ["left","top"];
panel1.spacing = 10;
panel1.margins = 10;

var button1 = panel1.add("button", undefined, undefined, {name: "button1"});
button1.text = "Open in Explorer";

button1.onClick = function(){Folder(activeDocument.path).execute();

}
dialog.show();
}

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Participant ,
Oct 19, 2021 Oct 19, 2021

Copy link to clipboard

Copied

1000 thanks for the quick help! 🙂

that really helps me! 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Oct 19, 2021 Oct 19, 2021

Copy link to clipboard

Copied

What exactly you do that sometimes your script crashes Photoshop?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Participant ,
Oct 20, 2021 Oct 20, 2021

Copy link to clipboard

Copied

Hi Kukurykus,

Without the Bridgetalk(); some Scripts close directly and some script crash Photoshop, but with Bridgetalt they all work perfectly 🙂

 

Thanks again!

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guide ,
Oct 20, 2021 Oct 20, 2021

Copy link to clipboard

Copied

LATEST

Scripts very rarely can crash photoshop, so it would be very interesting for us to look at the code that does this. Perhaps this would allow us to identify new bugs and also help other community users.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines