Use Photoshop JavaScript to Execute System Command

2019-08-29 04:28发布

I'm using Photoshop to automate processing images using action sets. I have added javascript to one of my action sets. I want to issue a windows command line prompt using the javascript. Is this possible? Is there some type of system_exec() function for doing this?

Edit: Here's an easy test

app.system("mshta javascript:alert(\"Hello World\");close();");

1条回答
何必那么认真
2楼-- · 2019-08-29 05:15

You can do this:

app.system("some Windows command")

E.g.

app.system("echo hi > C:\hi.txt")
查看更多
登录 后发表回答