$b=$host.UI.RawUI.ReadKey() $b.VirtualKeyCode -eq "13" #回车键Code为13 转载于:https://www.cnblogs.com/dreamer-fish/p/4110362.html