Results 1 to 5 of 5

Thread: TCP Monitor

  1. #1

    Thread Starter
    Fanatic Member BenJones's Avatar
    Join Date
    Mar 2010
    Wales UK

    TCP Monitor

    Hi this is my TCP monitor that monitors connections and the programs linked to the connections using Netstat from dos
    Shows Local and Remote address and ports
    Shows Process IDs and also the exe name that you can close.

    Please note this is only a beta I have more stuff to add, just thought I show off the first versions.
    Comments and suggestions welcome.

    Attached Files Attached Files

  2. #2
    New Member
    Join Date
    Oct 2014

    Exclamation Re: TCP Monitor

    Hi Sir, i'm using ultimate visual studio 2013 then i downloaded your file, but then, something wrong, i can't run/start the program. I'll send a print screen error. Please help me, thank you Name:  asd.jpg
Views: 1074
Size:  33.6 KB

  3. #3
    PowerPoster Nightwalker83's Avatar
    Join Date
    Dec 2001
    Adelaide, Australia

    Re: TCP Monitor

    Please post the code or error directly to the forums rather than posting a picture that is very difficult to read.
    when you quote a post could you please do it via the "Reply With Quote" button or if it multiple post click the "''+" button then "Reply With Quote" button.
    If this thread is finished with please mark it "Resolved" by selecting "Mark thread resolved" from the "Thread tools" drop-down menu.
    Please consider giving me some rep points if I help you a lot.
    Please rate my post if you find it helpful!
    Technology is a dangerous thing in the hands of an idiot! I am that idiot.

  4. #4
    Junior Member Alaa Ben Fatma's Avatar
    Join Date
    Dec 2014

    Re: TCP Monitor

    Good , I'm gonna Test It

  5. #5
    Frenzied Member
    Join Date
    Feb 2016

    Re: TCP Monitor

    Hi, I downloaded your project and I like it. I did have to make some changes because of exceptions, but that's cool. I need to ask you something though. Your software doesn't list all the programs that are connected to the net. Have you made any changes to the source code that will show all the programs? If so, I would like for you to post the new code.


    Edit: In case anyone wants to know what the fix was. Here it is...
        Private Sub ProcessData(ByVal Source As String)
            Dim Lines() As String = Source.Split(vbLf)
            Dim Parts() As String
            Dim Count As Integer = 0
            Dim ConnCount As Integer = 0
            Dim Splitter As Char() = {" "c}
            For Count = 0 To Lines.Count - 1
                'Trim down line.
                Dim sLine As String = Lines(Count).Trim()
                If Not String.IsNullOrEmpty(sLine) Then
                    If (Count > 3) Then
                        'Get TCP Connections.
                        If sLine.StartsWith("TCP") Then
                            'INC Counter
                            ReDim Preserve TCPConnections(ConnCount)
                            'Split line into 4 parts.
                            Parts = sLine.Split(Splitter, StringSplitOptions.RemoveEmptyEntries)
                            'Store TCP information.
                            With TCPConnections(ConnCount)
                                'Local address and port
                                .LocalAddr = Parts(1).Split(":")(0)
                                ' begin exception fix
                                ' first I had to change Parts to a string
                                Dim lportString As String = Parts(1).Split(":")(1).ToString
                                ' Then convert the string to Int32
                                If lportString <> Nothing Then
                                    Dim lportInt As Integer = Convert.ToInt32(lportString, 16)
                                    .LocalPort = lportInt
                                    ' end exception fix
                                    'Remote address and port
                                    .RemoteAddr = Parts(2).Split(":")(0)
                                    Dim rportString As String = Parts(2).Split(":")(1).ToString
                                    Dim rportInt As Integer = Convert.ToInt32(rportString, 16)
                                    .RemotePort = rportInt
                                    .State = Parts(3)
                                    .PID = CInt(Parts(4))
                                End If
                            End With
                            'INC connection counter
                            ConnCount += 1
                        End If
                    End If
                End If
            Next Count
            'Clear up
            Erase Lines
            Erase Parts
        End Sub
    Last edited by jumper77; Sep 8th, 2017 at 12:32 PM.
    I don't have a sig

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