[英]What would Environment.UserName return when used in a Windows Service
[英]Will Environment.UserName return the same result in Windows 7, Windows 8.x and Windows 10?
我需要在我正在处理的WPF应用程序中获取登录用户的名称。 几年前我见过这个问题 。 但现在我想知道Environment.UserName命令; 无论它是否在Windows 7,Windows 8.x或Windows 10计算机上运行,它都会返回相同的结果吗?
根据MSDN ,是的,它会。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.