通过 scriptcs 从 powershell 读取用户输入
Reading user input from powershell through scriptcs
我在通过 scriptcs.I 从命令提示符或 windows powershell 读取用户输入时遇到问题,尝试使用 Console.ReadLine()、Console.Read() 或 Console.ReadKey() 将其包裹在 Convert.ToString() 周围以获得用户响应,但其中 none 给出了 result.Do 我需要任何特殊包来处理用户输入。感谢您的帮助。
我得到了之前通过 Windows power shell 执行的解决方案,因此在使用 Console.ReadLine() 或 [=13= 时我没有得到所需的响应]()。看起来好像它被挂起并无限期地处理指令。但是当我在命令提示符下使用 scriptcs 代码时,它会读取输入并按预期工作。
我在通过 scriptcs.I 从命令提示符或 windows powershell 读取用户输入时遇到问题,尝试使用 Console.ReadLine()、Console.Read() 或 Console.ReadKey() 将其包裹在 Convert.ToString() 周围以获得用户响应,但其中 none 给出了 result.Do 我需要任何特殊包来处理用户输入。感谢您的帮助。
我得到了之前通过 Windows power shell 执行的解决方案,因此在使用 Console.ReadLine() 或 [=13= 时我没有得到所需的响应]()。看起来好像它被挂起并无限期地处理指令。但是当我在命令提示符下使用 scriptcs 代码时,它会读取输入并按预期工作。