|
|
Mail SlotA light-weight component for Visual Basic 6 programmers giving access to the Mail Slot API.Mail Slots are part of the Windows IPC (inter-process communication) services. They allow one computer to send messages to another or to broadcast messages to several other computers. Messages smaller than 425 bytes are sent as datagrams and can be broadcasted. The ability to broadcast a message over the network to any number of computers is very desirable in many cases. Using datagrams means that no open connection is needed to the remote computer(s).
The sequence for setting up a Mail Slot is easy. One computer creates the
Mail Slot, and can only read data. A remote computer can open the Mail Slot
and write data. Mail Slots are identified by names. You also supply a
computer name for the target computer - or use the Here is a sample VB6 server code:
and the client code...
This MailSlot component has a package size limit of about 200 characters. Characters are sent in UNICODE.
One example of how handy a Mail Slot can be is the MS SQL Server's
ability to provide a list of all known SQL Servers on the network. With
the simple broadcast technique that Mail Slots provide, a SQL Server simply
broadcasts its existence on the network when it boots up.
Known Bugs
Interface
Source Code DependenciesMicrosoft Visual C++ 6.0Microsoft ATL Library Installation Guide
Download Files
Written by Bjarke Viksoe. Article submitted 6/7/2001. To the top
|
|||||||||||||||||||||||||||