Search
Module:
Directory

   Desktop Functions:

   Smart Device Functions:


Show Recent Changes
Subscribe (RSS)
Misc. Pages
Comments
FAQ
Helpful Tools
Playground
Suggested Reading
Website TODO List
Download Visual Studio Add-In

EnumerateLocalComputerNames (kernel32)
 
.
Summary
Enumerates the local network names for the computer from which it is called.
Summary
TODO - a short description

C# Signature:

[DllImport("kernel32.dll", CharSet=CharSet.Auto)]
static extern uint EnumerateLocalComputerNames(
    COMPUTER_NAME_TYPE NameType,
    uint ulFlags,
    IntPtr lpBuffer,
    ref uint nSize);
[DllImport("kernel32.dll", SetLastError=true, CharSet=CharSet.Auto)]
static extern TODO EnumerateLocalComputerNames(TODO);

User-Defined Types:

COMPUTER_NAME_TYPE

None.

Notes:

Returns ERROR_SUCCESS on success or an error code on failure. Unless only the primary computer name is requested, the buffer will be filled with a series of null-terminated strings followed by a final null terminator. To measure the required number of characters, not including the final null terminator, use a null buffer and a zero size. This function is similar to GetComputerNameEx, and delegates to it to obtain the primary computer name.

None.

The caller may request the primary name only, the alternate names only, or all computer names. Each name returned is a fully qualified DNS name. This function has both ANSI and Unicode versions, but since it only exists on XP and later, the signature shown will always use Unicode.

Tips & Tricks:

Please add some!

Sample Code:

Please add some!

Alternative Managed API:

Do you know one? Please contribute it!

Documentation

Please edit this page!

Do you have...

  • helpful tips or sample code to share for using this API in managed code?
  • corrections to the existing content?
  • variations of the signature you want to share?
  • additional languages you want to include?

Select "Edit This Page" on the right hand toolbar and edit it! Or add new pages containing supporting types needed for this API (structures, delegates, and more).

 
Access PInvoke.net directly from VS:
Terms of Use
Edit This Page
Find References
Show Printable Version
Revisions