Click here to Skip to main content
15,894,955 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
i have added comments to where i have bugs
VB
Private Sub StopProxy()
        Dim Socket As AxMSWinsockLib.AxWinsock

        'looping each connections and close 'em
        SendToLog("Disconnecting all connection")
        For Each Socket In sckServer

            tmrServer(Socket.Index).Enabled = False 'the erro am having is index not a member of AxMSWinsockLib.AxWinsock
            tmrClient(Socket.Index).Enabled = False 'the erro am having is index not a member of AxMSWinsockLib.AxWinsock
            System.Windows.Forms.Application.DoEvents()
            CloseSocket(Socket.Index) 'the erro am having is index not a member of AxMSWinsockLib.AxWinsock
        Next Socket
        SendToLog("Proxy server stopped")
    End Sub
Posted
Comments
Sergey Alexandrovich Kryukov 7-Feb-15 10:39am    
Who told you that such thing exists? Why using DoEvents?
The question makes little sense as you don't telling us what are you trying to achieve or what your existing application did.
—SA
Dave Kreskowiak 7-Feb-15 21:38pm    
This is a smaller repost of the same question yesterday, here[^].

Yesterday, he asked if someone could fix all the errors in a LARGE code dump.

Basically, this thing needs to be scrapped and rewritten from scratch using the sockets support built into .NET.
Wolfsoftonline 7-Feb-15 10:43am    
I Upgrade My Program From 6.0 To .Net
Dave Kreskowiak 7-Feb-15 21:40pm    
I hate to tell you this, but running that code through the conversion wizard is a bit of a waste of time. You're old code is using the old Winsock control. This is a very outdated concept and, while still usable in VB.NET, you're be better off scrapping this code and rewriting it from scratch using the socket support built into .NET.

1 solution

 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900