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

NetBIOS (kernel32)
 
.
Summary
TODO - a short description

C# Signature:

[StructLayout(LayoutKind.Sequential, CharSet=CharSet.Ansi)]
public struct _NCB
{
    public Commands ncb_command;      /* command code           */
    public byte   ncb_retcode;        /* return code            */
    public byte   ncb_lsn;        /* local session number       */
    public byte   ncb_num;        /* number of our network name     */
    //[MarshalAs(UnmanagedType.ByValArray, SizeConst = NCBNAMSZ)]
    //[MarshalAs(UnmanagedType.LPStr)]
    //[MarshalAs(UnmanagedType.LPArray)]
    public IntPtr ncb_buffer;         /* address of message buffer      */
    public ushort ncb_length;         /* size of message buffer     */
    [MarshalAs(UnmanagedType.ByValArray, SizeConst = NativeMethods.NCBNAMSZ)]
    public byte[]   ncb_callname; /* blank-padded name of remote    */
    [MarshalAs(UnmanagedType.ByValTStr, SizeConst = NativeMethods.NCBNAMSZ)]
    public byte[]   ncb_name;         /* our blank-padded netname       */
    public byte   ncb_rto;        /* rcv timeout/retry count    */
    public byte   ncb_sto;        /* send timeout/sys timeout       */
    public IntPtr postroutine;//void (CALLBACK *ncb_post)( struct _NCB * ); /* POST routine address    */
    public byte   ncb_lana_num;       /* lana (adapter) number      */
    public byte   ncb_cmd_cplt;       /* 0xff => commmand pending       */
    [MarshalAs(UnmanagedType.LPArray, SizeConst=10)]
    public byte[/*10*/]   ncb_reserve;    /* reserved, used by BIOS     */
    public IntPtr  ncb_event;         /* HANDLE to Win32 event which    */
                    /* will be set to the signalled   */
                    /* state when an ASYNCH command   */
                    /* completes              */
}

[DllImport("kernel32.dll", SetLastError=true)]
static extern byte Netbios(_NCB controlBlock);

VB Signature:

Declare Function NetBIOS Lib "kernel32.dll" (TODO) As TODO

User-Defined Types:

None.

Notes:

None.

Tips & Tricks:

Please add some!

Sample Code:

Please add some!

Alternative Managed API:

Do you know one? Please contribute it!

Documentation
NetBIOS on MSDN

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
Find References
Show Printable Version
Revisions