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

Trying to automate a set of commands with "Actions" but some commands fail

Community Beginner ,
Jul 28, 2020 Jul 28, 2020

Copy link to clipboard

Copied

Hello ,

I want to do the following to some contiguous paths in a drawing :

step 1 : select paths (Not in the action)

step 2 : stroke weight=0 (or stroke color = none)

step 3 : go to background

step 4 : copy

step 5 : paste in front

step 6 : pathfinder unite

step 7 : stroke weight 2

step 8 : fill color = none

step 9 : bring to front

I tried to record it but the result is not satisfactory as step 2 and step 8 fail.

I noticed thet when I try to change the stroke color to "none" (step 2) or input "0" for stroke weight, the recorder records nothing. Same for step 8, I choose color "none" on the palette (not using swatches) but it is NOT recorded.

Tried to edit the .aia file to no avail

Can't figure out a way to do it.

Any help would be appreciated (I use this set of commands A LOT) !

 

Best regards,

Philippe

TOPICS
Draw and design , Scripting

Views

323

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

Community Expert , Jul 29, 2020 Jul 29, 2020

Can you try it again with this englishyfied version, Philippe?

 

https://drive.google.com/file/d/1-ThIjGpoxrI4_hEMD1tchB-RkebKoJAK/view?usp=sharing

Votes

Translate

Translate
Adobe
Community Expert ,
Jul 28, 2020 Jul 28, 2020

Copy link to clipboard

Copied

Can you share the action file (.aia) in its current state with the missing steps?

 

Also, what is the general purpose of the action? Just asking because I can imagine that there may be an easier way to achieve what you (probably) want.

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
Community Beginner ,
Jul 28, 2020 Jul 28, 2020

Copy link to clipboard

Copied

Thank you Kurt for the prompt answer.

Here is the .aia

 

/version 3
/name [ 5
5365742032
]
/isOpen 1
/actionCount 1
/action-1 {
/name [ 8
416374696f6e2034
]
/keyIndex 0
/colorIndex 0
/isOpen 1
/eventCount 8
/event-1 {
/useRulersIn1stQuadrant 0
/internalName (ai_plugin_setColor)
/localizedName [ 9
53657420636f6c6f72
]
/isOpen 0
/isOn 1
/hasDialog 0
/parameterCount 2
/parameter-1 {
/key 1768186740
/showInPalette -1
/type (ustring)
/value [ 12
5374726f6b6520636f6c6f72
]
}
/parameter-2 {
/key 1718185068
/showInPalette -1
/type (boolean)
/value 0
}
}
/event-2 {
/useRulersIn1stQuadrant 0
/internalName (adobe_sendToBack)
/localizedName [ 12
53656e6420746f204261636b
]
/isOpen 0
/isOn 1
/hasDialog 0
/parameterCount 0
}
/event-3 {
/useRulersIn1stQuadrant 0
/internalName (adobe_copy)
/localizedName [ 4
436f7079
]
/isOpen 0
/isOn 1
/hasDialog 0
/parameterCount 0
}
/event-4 {
/useRulersIn1stQuadrant 0
/internalName (adobe_pasteInFront)
/localizedName [ 14
506173746520696e2046726f6e74
]
/isOpen 0
/isOn 1
/hasDialog 0
/parameterCount 0
}
/event-5 {
/useRulersIn1stQuadrant 0
/internalName (ai_plugin_pathfinder)
/localizedName [ 10
5061746866696e646572
]
/isOpen 0
/isOn 1
/hasDialog 0
/parameterCount 1
/parameter-1 {
/key 1851878757
/showInPalette -1
/type (enumerated)
/name [ 3
416464
]
/value 0
}
}
/event-6 {
/useRulersIn1stQuadrant 0
/internalName (ai_plugin_setStroke)
/localizedName [ 10
536574205374726f6b65
]
/isOpen 0
/isOn 1
/hasDialog 0
/parameterCount 7
/parameter-1 {
/key 2003072104
/showInPalette -1
/type (unit real)
/value 2.0
/unit 592476268
}
/parameter-2 {
/key 1667330094
/showInPalette -1
/type (enumerated)
/name [ 8
4275747420436170
]
/value 0
}
/parameter-3 {
/key 1836344690
/showInPalette -1
/type (real)
/value 10.0
}
/parameter-4 {
/key 1785686382
/showInPalette -1
/type (enumerated)
/name [ 10
4d69746572204a6f696e
]
/value 0
}
/parameter-5 {
/key 1684825454
/showInPalette -1
/type (integer)
/value 0
}
/parameter-6 {
/key 1684104298
/showInPalette -1
/type (boolean)
/value 0
}
/parameter-7 {
/key 1634494318
/showInPalette -1
/type (enumerated)
/name [ 6
43656e746572
]
/value 0
}
}
/event-7 {
/useRulersIn1stQuadrant 0
/internalName (ai_plugin_setColor)
/localizedName [ 9
53657420636f6c6f72
]
/isOpen 0
/isOn 1
/hasDialog 0
/parameterCount 2
/parameter-1 {
/key 1768186740
/showInPalette -1
/type (ustring)
/value [ 10
46696c6c20636f6c6f72
]
}
/parameter-2 {
/key 1718185068
/showInPalette -1
/type (boolean)
/value 1
}
}
/event-8 {
/useRulersIn1stQuadrant 0
/internalName (adobe_sendToFront)
/localizedName [ 14
4272696e6720746f2046726f6e74
]
/isOpen 0
/isOn 1
/hasDialog 0
/parameterCount 0
}
}

 

To tell you what I want to do (see attached example images) :

I want to be able to handle objects and outlines separtely and decide which object(s) should be outlined and which should not.

in my example I may want to have the green rectangle in the same "fence" as the red and blue.

But I also could decide to have green in its outline and red+blue in an other outline (hide layer 1b and show layer 1 to see what I mean).

in a nutshell : layer 1 + layer2 +layer3 (image 1) OR layer 1b + layer2 +layer4 (image 2)image2.jpgimage1.jpg

Of course the example is not mindblowingly significant but it all ends up to art, take my word for it ;-).

Is it clearer ?

Any idea welcome !!

 

Best regards,

 

Philippe

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
Community Expert ,
Jul 29, 2020 Jul 29, 2020

Copy link to clipboard

Copied

I've added the missing steps and also made a simplified version.

 

You can download the action set (including two actions) here:

 

https://drive.google.com/file/d/1SGDI14DTSgW8frN20xsgWV-wzBBXn3Ge/view?usp=sharing

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
Community Beginner ,
Jul 29, 2020 Jul 29, 2020

Copy link to clipboard

Copied

Hey Kurt,

Many thanks for your time and expertise.

It is one inch to work on my machine.

One problem is when loading the steps where you have "Apply Swatch : [Ohne]" I get an error "Swatch not found"

I thought it was because you wrote it with a German speaking machine so edited [Ohne] with [None].... DID NOT WORK !

I tried to replace EVERY German word in the code, it ended up in AI refusing to load the Action...

You are very close to the solution (btw, I like the "simplified" version)

Am I being too pushy to ask wether you can find another way ?...

Thank you anyway for the time spent.

 

Cheers !

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
Community Expert ,
Jul 29, 2020 Jul 29, 2020

Copy link to clipboard

Copied

Can you try it again with this englishyfied version, Philippe?

 

https://drive.google.com/file/d/1-ThIjGpoxrI4_hEMD1tchB-RkebKoJAK/view?usp=sharing

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
Community Beginner ,
Jul 29, 2020 Jul 29, 2020

Copy link to clipboard

Copied

GREAT !!

First scripts does exactly what I was looking for !

I really and sincerely thank you for your patience, commitment,... in one word : your HELP.

I love the Internet for that. I've made my first website back in 1994. Now I'm retired and still try to express myself with computers but in art this time.

Please come and visit my website www.philippematine.com and you'll better understand why I needed this script.

 

Hope our paths will cross some other time.

I owe you one but I'm not sure to be skilled enough to pay you back.

 

Mit freundlichen Grüßen

 

Philippe

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
Community Expert ,
Jul 29, 2020 Jul 29, 2020

Copy link to clipboard

Copied

LATEST

You are welcome. I'm glad that it worked this way.

 

At the same time I'm a bit angry that the records of actions do not work anymore as they used to work in former times. They used to work independent of the (language) version you were using when recording them. That is, for example, when applying a swatch of [Ohne] in a German version of Illustrator, it has been automatically converted to a swatch of [None] if you were using the action in an English version of Illustrator (or at least the English version knew that "Ohne" is "None").

 

Unfortunately, some other things do not work as they used to do in conjuction with setting up actions, but that's another issue.

 

Actions were international cases, but apparently they should not be it at the moment ...

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