I need to use the following API communication functions.
Private Declare Function GetCommMask Lib "kernel32" (ByVal hFile As Long,
lpEvtMask As Long) As Long
Private Declare Function SetCommMask Lib "kernel32" (ByVal hFile As Long,
ByVal dwEvtMask As Long) As Long
Private Declare Function WaitCommEvent Lib "kernel32" (ByVal hFile As Long,
lpEvtMask As Long,lpOverlapped As OVERLAPPED) As Long
Has someone examples in VB which demonstrate the using of these functions ?
I have problem to understand the use of the parameter ......lpEvtMask As
Long........ etc. .
How is the access to the data behind lpEvtMask parameter in VB ?
Thank you for every help.
Urs Aeschlimann
I have example code and a long-winded explaination in my book. See below.
Your question is not one that can be answered simply.
BTW, I do not know of any online source that explains the Windows
communications API. Also, I continue to suggest that people use either
MSComm32.ocx, or download XMCommCRC.ocx from my homepage. These are MUCH
easier to use than the API, and actually perform better than pure VB code.
Naturally, there are commercial comms add-ons that provide even more
features. These I describe in detail in my book, and provide working code
examples across the genre.
--
Richard Grier (Microsoft Visual Basic MVP)
Hard & Software
12962 West Louisiana Avenue
Lakewood, CO 80228
303-986-2179 (voice)
303-986-3143 (fax)
Leave voice mail or fax that I can receive as email at 303-593-9315
Author of Visual Basic Programmer's Guide to Serial Communications, 2nd
Edition ISBN 1-890422-25-8 (355 pages).
For information look on my homepage at http://www.hardandsoftware.net.
Use the Books link to order. For faster service contact the publisher at
http://www.mabry.com.