Accessing Events within a VB DLL

Can I trap for the IPPORT1_DataIn event within a DLL?

Date Entered: 02/17/1998    Last Updated: 06/09/2004

Create the object in the following manner:
   Private tcpLog as IPPORT

The 'Dim WithEvents' in VB 5 or higher can only be called from a Class module (*.cls) and once called, you then have the events available within the in-process server as shown below:

             
     'create instance of object for early binding
     Private WithEvents tcpLog As IPPort

Then to access the event:

     Private Sub tcpLog_DataIn(Text As String, EOL As Integer)
         myRetVal = Text
     End Sub


We appreciate your feedback.  If you have any questions, comments, or suggestions about this entry please contact our support team at kb@nsoftware.com.