Its almost always going to be a list because of the input declaration and the assumption that you will be sending a list of items. What I was pointing out in my screenshot is that you can setup your automator workflow and then confirm the class in the AppleScript script.
If you are thinking about object oriented scripting, I would suggest working directly in the Script Editor.
Why not just tell us what issue you are solving for?
When I put a "Run Applescript" action at the top of the workflow to create a service, I can select what can of input I get.
The options are "Service receives selected" + dropdown menu where you have a Text category, a File and Folders category, and an Other category, all received from either any application of from a specified application.
This input is passed to the Applescript on run handler as "input", but nowhere is it said that the input is *almost always* a list and that's the information I was looking for.
So I was struggling with some "text" input that I thought was a string when it was in fact a list. That was very confusing. I ended up checking class of input, which brought the "list" class, but it took me a while to figure out that I had an issue here.
Hence the question, though badly worded.
Now, if you could tell the cases when it is *not* a list that would be extra nice.
Also, I can't work directly into SE because I want to work with the Automator input, which I can't really simulate in SE.
Jean-Christophe
On Apr 12, 2017, at 10:00 AM, Jean-Christophe Helary <
email@hidden> wrote:
Yes I can see that, but what about the input that the script gets from Automator itself, like text from any application or Files etc...
I actually checked on the developer site and found the following:
I don't know what can be the cases where the input is not a list but that will do for now. :)
Jean-Christophe
On Apr 12, 2017, at 23:30, Chip Wathey <
email@hidden> wrote:
This is easily solved by just asking for the class inside the script.
<PastedGraphic-1.png>
Do not post admin requests to the list. They will be ignored.
Automator-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden