在python中启动illustrator程序:
app = com.Dispatch("Illustrator.Application")
ret = app.DoJavaScriptFile(r"E:\pycode\illustrator\illustrator-scripts-master\jsx\chuyin_checkLayer.jsx",arguments, 1)
1.ret用来接收jsx脚本return的结果
2.arguments为传递进jsx脚本中的参数,类型是一个数组
在jsx是取参数为固定的变量名,这个变量名是无法自定义名字的
在jsx文件中取参数:
main(arguments);
1.main为自定义函数
2.arguments为python传过来的参数,是一个数组,这里的arguments不能改成其他名字,否则接收不到python传过来的参数