Using Win32 functions in Visual FoxPro Image Gallery
Mailslot
..msdn
CreateMailslot
GetMailslotInfo
SetMailslotInfo
Code examples:
Creating a mailslot
Peer-to-peer LAN messenger built with Mailslot API functions
CreateMailslot
..msdn    Add comment     W32 Constants      Translate this page
The CreateMailslot function creates a mailslot with the specified name and returns a handle that a mailslot server can use to perform operations on it.
Code examples:
Peer-to-peer LAN messenger built with Mailslot API functions
Creating a mailslot
Declaration:
HANDLE CreateMailslot(
  LPCTSTR lpName,                 // mailslot name
  DWORD nMaxMessageSize,          // maximum message size
  DWORD lReadTimeout,             // read time-out interval
  LPSECURITY_ATTRIBUTES lpSecAttr // inheritance option
);
FoxPro declaration:
DECLARE INTEGER CreateMailslot IN kernel32;
    STRING  lpName,;
    INTEGER nMaxMessageSize,;
    INTEGER lReadTimeout,;
    INTEGER lpSecurityAttributes
Parameters:
lpName
[in] Pointer to a null-terminated string specifying the name of the mailslot.

nMaxMessageSize
[in] Specifies the maximum size, in bytes, of a single message that can be written to the mailslots.

lReadTimeout
[in] Specifies the amount of time, in milliseconds, a read operation can wait for a message to be written to the mailslot before a time-out occurs.

lpSecurityAttributes
[in] Pointer to a SECURITY_ATTRIBUTES structure.
Return value:
If the function succeeds, the return value is a handle to the mailslot, for use in server mailslot operations.
My comment:
The mailslot exists until one of the following conditions is true:
  • The last (possibly inherited or duplicated) handle to it is closed using the CloseHandle function.
  • The process owning the last (possibly inherited or duplicated) handle exits.

    The system uses the second method to destroy mailslots.
  • Word Index links for the CreateMailslot :
    Translate this page:
      Spanish    Portuguese    German    French    Italian  
    FreeTranslation.com offers instant, free translations of text or web pages.
    Created: 2002-01-26 14:23:46
    Modified: 2002-01-26 14:30:31
    Visited in last 7 days: 26
    User Contributed Notes:
    There are no notes on this subject.


    Copyright 2001-2017 News2News, Inc. Before reproducing or distributing any data from this site please ask for an approval from its owner. Unless otherwise specified, this page is for your personal and non-commercial use. The information on this page is presented AS IS, meaning that you may use it at your own risk. Microsoft Visual FoxPro and Windows are trade marks of Microsoft Corp. All other trademarks are the property of their respective owners. 

    Privacy policy
    Credits: PHP (4.4.9), an HTML-embedded scripting language, MySQL (5.6.38), the Open Source standard SQL database, AceHTML Freeware Version 4, freeware HTML Editor of choice.   Hosted by Korax Online Inc.
    Last Topics Visited (54.81.178.153)
    11 sec.Function: 'SQLDrivers'
    21 sec.Function: 'CopyImage'
    31 sec.Function: 'SetClipboardData'
    41 sec.Function: 'GetUserName'
    53 sec.Function: 'NetUserGetInfo'
    1.05 min.Function: 'RevertToSelf'
    1.22 min.Function: 'UpdateResource'
    1.38 min.Function: 'ConnectNamedPipe'
    1.57 min.Function: 'SendARP'
    1.75 min.Function: 'SetVolumeLabel'
    Google
    Advertise here!