How to Use WNetGetUser() in Windows for Workgroups from VB 3.0 (113688)
The information in this article applies to:
- Microsoft Visual Basic Standard Edition for Windows 2.0
- Microsoft Visual Basic Standard Edition for Windows 3.0
- Microsoft Visual Basic Professional Edition for Windows 2.0
- Microsoft Visual Basic Professional Edition for Windows 3.0
This article was previously published under Q113688 SUMMARY
The information from this article is taken from the following Microsoft
Knowledge Base article:
96772
: INF: How to Use WNetGetUser() in Windows for Workgroups
The information is duplicated here to include sample code that is converted
for use in Visual Basic.
WNetGetUser() is documented on page 194 in the Microsoft Windows Device
Driver Kit (DDK) "Device Driver Adaptation Guide" for version 3.1. This
function can be used to retrieve the current user name of the user logged
on to the network underlying Windows. However, when using this function in
Microsoft Windows for Workgroups, WNetGetUser() returns WN_SUCCESS but the
user name string is empty. Because WFWNET.DRV is a multinet driver, the
network that supports WNetGetUser() must be activated before using this
function.
Modification Type: | Major | Last Reviewed: | 12/9/2003 |
---|
Keywords: | KB113688 |
---|
|