How to get logged-in user's full name in windows?

后端 未结 6 2074
借酒劲吻你
借酒劲吻你 2020-11-30 13:07

How to get logged-in user\'s full name (the one he/she entered as his/her real name) using windows API or something else? For example how to get \"John Smith\", not \"john\"

6条回答
  •  既然无缘
    2020-11-30 13:36

    NetQueryDisplayInformation should help. The field usri1_full_name will give the full name

提交回复
热议问题