有没有办法设置窗口,让控制台窗口打开? [英] Is there a way to set windows to leave console windows open?

查看:172
本文介绍了有没有办法设置窗口,让控制台窗口打开?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有办法让它停止关闭,一旦代码完成,所以我可以读取终止脚本中的错误消息?
我知道各种不同语言的命令可以用来等待用户输入一个字符。我询问是否有一种方法可以设置窗口本身使该窗口全局或特定类型的程序打开,以便可以读取错误消息,没有任何特殊的使用条件(如

Is there some way to get it to stop closing as soon as the code finishes so I can actually read the error messages in termination scripts? I know that various commands in different languages can be used to make it wait for the user to enter a character. I am asking if there is a way to set windows itself to leave the window open either universally or for specific types of programs so that error messages can be read without any special usage conditions (such as calling from inside CMD) or added coding (such as a user input command at the end of the code).

推荐答案

p>尝试在cmd窗口中运行命令(只需在运行框中键入cmd,然后键入其路径即可执行程序)。这将使cmd窗口即使在程序结束后也打开,并且您还可以设置窗口的缓冲区长度,如果您的错误消息太长。

Try running the command in a cmd window (just type cmd in the Run box and execute your program by typing the path to it). This will have the cmd window open even after the program has ended and you can also set a buffer length for the window if your error messages are too long.

这篇关于有没有办法设置窗口,让控制台窗口打开?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆