Results 1 to 2 of 2

Thread: Catching events for control arrays created at runtime

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Jul 1999
    Location
    Phoenix
    Posts
    87
    WithEvents does not work. That only works for a single control. I'm using

    Code:
    Public sckConnections() as winsock
    I allocate winsock objects as they are needed and give them back when not needed. However, I can't catch any of the events for this control array. All the code is in a class module so I don't have the control array on the form.

    Can this be done?

  2. #2
    Guest
    I think you can preset stuff.

    For example, just put this in your class and when error comes up, Winsock will catch it.

    Code:
    Private Sub sckSend_Error(ByVal Number As Integer, _
    Description As String, ByVal Scode As Long, ByVal Source As _
    String, ByVal HelpFile As String, ByVal HelpContext As _
    Long, CancelDisplay As Boolean)
         MsgBox "An error occurred in winsock!"
         End
    End Sub

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width