Q: Is it possible to execute a console command somehow?

Discuss and share scripts and script files...
Post Reply
Walrez
Posts: 29
Joined: 05 May 2008 16:42

Q: Is it possible to execute a console command somehow?

Post by Walrez »

I mean, an internal cmd command, like copy, dir, echo, etc?

admin
Site Admin
Posts: 66254
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: Q: Is it possible to execute a console command somehow?

Post by admin »

Walrez wrote:I mean, an internal cmd command, like copy, dir, echo, etc?
This will do "DIR C:" in the console box:
::open "cmd" /k dir c:\

cmd.exe switches (there are more...):
/c Carries out the command and then terminates
/k Carries out the command but remains

More elegant would be to add a new scripting command "cmd" and have:
cmd command, [remain=1]
::cmd "dir c:"

Walrez
Posts: 29
Joined: 05 May 2008 16:42

Post by Walrez »

Thanks, I used it for the "FTP panel" script that I just posted.

Post Reply