在 Windows 服务器域内检索用户的名字和姓氏(给定其登录名)

发布于 2024-09-28 10:01:56 字数 174 浏览 1 评论 0原文

鉴于我位于 Windows Server 域内的工作站上。 在我的数据中,我有创建数据的操作员的登录名。

当我打印此数据的演示文稿时,我想显示名字和姓氏 该操作员的信息,可能会登录到该域的另一个工作站...甚至可能根本无法登录。

您知道我是否可以实现这一目标以及如何实现吗?

提前谢谢。

Given that I am on a workstation, that is inside a Windows Server domain.
In my data, I have the login name of the operator who has created the data.

When I print a presentation of this data, I want to display the first and last name
of this operator, which may be logged on another workstation of the domain... or even could even not be logged at all.

Do you have any clue if I can acheive this, and how ?

In advance thx.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

じ违心 2024-10-05 10:01:56

Win32_UserAccount WMI 类有一个FullName 属性听起来好像是有可能的。

也许是这样的查询:

SELECT * FROM Win32_UserAccount WHERE Name='username'

然后您可以从该查询的结果中查询 FullName

此 MSDN 页面包含有关从 C++ 使用 WMI 的信息: WMI C++应用实例

The Win32_UserAccount WMI class, has a FullName property which sounds like it might be a possibility.

Maybe a query like:

SELECT * FROM Win32_UserAccount WHERE Name='username'

And then you can query the results from that query for the FullNames.

This MSDN page has information about using WMI from C++: WMI C++ Application Examples

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文