简体   繁体   English

运行Perl程序后如何关闭Windows CMD窗口?

[英]How can I close a Windows CMD window after I run a Perl program?

有没有一种方法可以在任务完成后关闭cmd窗口,并告诉您已经打开了多少个窗口?

system( qq{ start "List Perl files" perl c:/perlscripts/new_spider.pl $new_href } )

The command to close a window is 关闭窗口的命令是

exit

However, when I tried your code (Win7) the cmd window closed without any help from me. 但是,当我尝试使用您的代码(Win7)时,cmd窗口没有我的帮助就关闭了。

Take a look at new_spider.pl and double-check there's nothing holding the cmd window open in there. 看一下new_spider.pl并再次检查是否没有任何东西可以在其中打开cmd窗口。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM