Welcome Dialog

Welcome to the Community!

We have a brand new look! Take a tour with us and explore the latest updates on Adobe Support Community.


aerender Illegal argument flag with Swift "Front End"

Community Beginner ,
Aug 07, 2016 Aug 07, 2016

Copy link to clipboard

Copied

I built a simple desktop app in Swift that gives aerender a user interface.  When I use it to fire off a simple render it is giving me "Illegal argument flag" when the exact same command typed in to the terminal works fine.  For example  when you use the "-project" flag followed by the file-path to the AE project.  Ive tried formatting the file path string a number of ways and playing with adding spaces (like after the "-project" text before the file-path).  My app displays the output of the command line (stdout) in the interface window so you can see all of the neat stuff like "launching After Effects".

I had it working fine for a while, but it started having this problem when I started putting the command in a NSTask function.  I did this so I could monitor the output (stdout) in my interface.

Does aerender have permission issues when receiving arguments from NSTask?  Has anyone else messed around with NSTask and aerender?  Any Swift coders out there?

Im happy to provide more info if needed, but i wanted to keep this post simple 🙂

Thanks all!

-Jacob

Screen Shot 2016-08-07 at 3.49.46 PM.png

TOPICS
SDK

Views

561

Likes

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 Beginner , Sep 06, 2016 Sep 06, 2016
I'm sure my question above made no sense.   I tend to ramble...  but for anyone who is interested, I got this to work.  I re-wrote the app using Objective-C instead of Swift.  For some reason I wasn't able to wrap my head around the NSTask problem in Swift.  All I can figure is that aerender is super sensitive about how the file-path string is formatted.-Jacob

Likes

Translate

Translate
Community Beginner ,
Sep 06, 2016 Sep 06, 2016

Copy link to clipboard

Copied

I'm sure my question above made no sense.  🙂 I tend to ramble...  but for anyone who is interested, I got this to work.  I re-wrote the app using Objective-C instead of Swift.  For some reason I wasn't able to wrap my head around the NSTask problem in Swift.  All I can figure is that aerender is super sensitive about how the file-path string is formatted.

-Jacob

Likes

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 ,
Apr 21, 2021 Apr 21, 2021

Copy link to clipboard

Copied

LATEST

I'd like to know how did you rewrote the NSTask call in Obj-C.

In what it diffres from Swift?

I'm stuck with the same problem.

I tried to write a NSTask call in Obj-C but the result is the same!  😞

Likes

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