Results 1 to 7 of 7

Thread: To IP or not to IP

  1. #1

    Thread Starter
    Member Chipcrap's Avatar
    Join Date
    Mar 2001
    Posts
    52

    Lightbulb

    I'm working on developing an internet file sharing aplication-sort of like napster, but not limited to MP3 files.
    I understand that using a dialup is NOT the best way to do this, but I am on a budget. I was thinking of setting up a server app that would distribute all of the current shared files to each client, and send out IP addresses if someone wanted to download a file from another computer. Then client 1 would connect to client 2 and start the transfer.

    What I need to know, is how to determine the clients current IP address.

    Also-I use a dialup internet connection, and my IP changes everytime I dial in. How would I go about letting the clients know the current server IP? I could have the server store the current IP on a txt file on the internet and have the clients check there first. Any suggestions??

    THX!

  2. #2
    Lively Member
    Join Date
    Apr 2001
    Location
    Central NC
    Posts
    75
    From a winsock control, look at .LocalIP

  3. #3

    Thread Starter
    Member Chipcrap's Avatar
    Join Date
    Mar 2001
    Posts
    52
    I thought your local IP and the IP used to connect to your machine over the ineternet were different numbers? Doesn't that call just give your local IP adress?
    Last edited by Chipcrap; Apr 4th, 2001 at 03:17 PM.

  4. #4
    Lively Member
    Join Date
    Apr 2001
    Location
    Central NC
    Posts
    75
    Sorry, my brain went into 'how do I get my IP' mode.

    In any case, in everything I've written in which I need to tell a remote what my IP is, I use .LocalIP.

    Yeah, having the client fetch it from a fixed location you update as needed is about all you can do for now.

  5. #5

    Thread Starter
    Member Chipcrap's Avatar
    Join Date
    Mar 2001
    Posts
    52
    The only probem I have with the local IP number-
    Example: Everyone who had networking done by Company A uses 192.168.0.1 for the local server IP on their LAN. If they try to use my software my server app will get several connections at 192.168.0.1-won't this cause the Winsock.Sendata to send stuff to everyone with the same IP?

  6. #6

    Thread Starter
    Member Chipcrap's Avatar
    Join Date
    Mar 2001
    Posts
    52
    Ok I think I found the answer:

    Winsock.RemoteHostIP

    Hopefully this will work for my project and give the IP address that I need

    Thanks cookre!

  7. #7
    Frenzied Member
    Join Date
    Jan 2000
    Location
    Bellevue, WA, USA
    Posts
    1,357
    What about your customers who connect through a proxy server?
    ~seaweed

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