Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. C#
  4. problem with TCP connection [modified]

problem with TCP connection [modified]

Scheduled Pinned Locked Moved C#
sysadminalgorithmstestingbeta-testinghelp
3 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    johland
    wrote on last edited by
    #1

    hi, i'm trying to write a compact file sharing application- server side and client. client connect to the server given port and ip (for searching files)and at the same time listening on a different port to other clients trying to connect (file transfering requests). while connected to the server and listening for incoming clients requests he can connect to other clients (for receiving files). i have problem testing this application on my computer: after connecting to server and starting to listen, when the client trying to create a new TcpClient connection object i get the TcpClient Exception:"The requested address is not valid in its context" thanks in advance yohay

    modified on Thursday, June 5, 2008 8:29 AM

    realJSOPR 1 Reply Last reply
    0
    • J johland

      hi, i'm trying to write a compact file sharing application- server side and client. client connect to the server given port and ip (for searching files)and at the same time listening on a different port to other clients trying to connect (file transfering requests). while connected to the server and listening for incoming clients requests he can connect to other clients (for receiving files). i have problem testing this application on my computer: after connecting to server and starting to listen, when the client trying to create a new TcpClient connection object i get the TcpClient Exception:"The requested address is not valid in its context" thanks in advance yohay

      modified on Thursday, June 5, 2008 8:29 AM

      realJSOPR Offline
      realJSOPR Offline
      realJSOP
      wrote on last edited by
      #2

      This usually results from an attempt to bind a listening socket to an IP address that's not valid for the local machine. Are you using 127.0.0.1 as your ip address in the client (on the local machine)?

      "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
      -----
      "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001

      J 1 Reply Last reply
      0
      • realJSOPR realJSOP

        This usually results from an attempt to bind a listening socket to an IP address that's not valid for the local machine. Are you using 127.0.0.1 as your ip address in the client (on the local machine)?

        "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
        -----
        "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001

        J Offline
        J Offline
        johland
        wrote on last edited by
        #3

        yes..(or tcpClient=new TcpClient("localhost", 9355);)

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups