Skip to main content
Inspiring
Mar 27, 2025 4:24 PM UTC
Answered

Alternative for app.executeMenuCommand("join")?

Does jsx have alternative for this app.executeMenuCommand("join")?
Are there method with which is possible to apply join on two or more objects?


Or are there any other alternative for this?

Sergey Osokin
Sergey OsokinCorrect answer
Inspiring
Mar 29, 2025 1:01 PM UTC

To join objects, the script needs to know which objects the user wants to join. You can try to collect all points of vector paths into an array and create a new pathItem with myPath.setEntirePath(points), while deleting the original paths.

4 replies

renél80416020
Inspiring
Mar 28, 2025 8:51 AM UTC

Bonjour,

Sélectionnez les tracés à joindre...

// JavaScript Document
// Objet > Tracé > joindre
// -------
(function () {
if (selection.length) {
      app.executeMenuCommand('join');
}
})();

 

Translate
Inspiring
Mar 28, 2025 11:48 AM UTC

Question was Alternative for app.executeMenuCommand("join").

To do join without need to select objects with some other method or approach.

Translate
Sergey Osokin
Sergey OsokinCorrect answer
Inspiring
Mar 29, 2025 1:01 PM UTC

To join objects, the script needs to know which objects the user wants to join. You can try to collect all points of vector paths into an array and create a new pathItem with myPath.setEntirePath(points), while deleting the original paths.

Translate