This may help you or try
www.planetsourcecode.com
++++++++++++++++++++++++++++++++++++++
Private Sub acomm_OnComm()
Select Case acomm.CommEvent
' Handle each event or error by placing
' Errors
Case comEventBreak ' A Break was received.
Case comEventCDTO ' CD (RLSD) Timeout.
Case comEventCTSTO ' CTS Timeout.
Case comEventDSRTO ' DSR Timeout.
Case comEventFrame ' Framing Error.
Case comEventOverrun ' Data Lost.
Case comEventRxOver ' Receive buffer overflow.
Case comEventRxParity ' Parity Error.
Case comEventTxFull ' Transmit buffer full.
Case comEventDCB ' Unexpected error retrieving DCB
' Events
Case comEvCD ' Change in the CD line.
Case comEvCTS ' Change in the CTS line.
Case comEvDSR ' Change in the DSR line.
Case comEvRing ' Change in the Ring Indicator.
Case comEvReceive ' Received RThreshold # of chars.
Case comEvSend ' There are SThreshold number of characters in the transmit buffer.
Case comEvEOF ' An EOF character was found in the input stream.
End Select
End Sub