Results 1 to 8 of 8

Thread: RemoteHostIP snafoo

  1. #1

    Thread Starter
    New Member
    Join Date
    Sep 2004
    Posts
    6

    RemoteHostIP snafoo

    I am writing a fairly basic chat programn using winsocks in vb6. To do testing, i am using a PC with ethernet and a laptop on a wireless connection. I'm not sure how the network is structured (i.e., what goes on with the wireless connections) because this is a college campus. However, when i have the laptop connect to the PC, the RemoteHostIP property of the server winsock on the PC contains an address that is not the IP of the laptop. I need this property to keep my connections straight, so any insights would be very helpful.

    Roush

  2. #2
    PowerPoster
    Join Date
    Dec 2003
    Posts
    4,787

    Re: RemoteHostIP snafoo

    Quote Originally Posted by JRoush
    I am writing a fairly basic chat programn using winsocks in vb6. To do testing, i am using a PC with ethernet and a laptop on a wireless connection. I'm not sure how the network is structured (i.e., what goes on with the wireless connections) because this is a college campus. However, when i have the laptop connect to the PC, the RemoteHostIP property of the server winsock on the PC contains an address that is not the IP of the laptop. I need this property to keep my connections straight, so any insights would be very helpful.

    Roush
    If you are connected from pc to laptop then winsock.remotehostip will return the ip of the connected pc\laptop\etc, it may be an issue with the network setup, ie the ip you are getting is the routers ip, try doing winsock.localip from the laptop and seeing if it matches the winsock.remotehostip from the pc.

    Pino

  3. #3

    Thread Starter
    New Member
    Join Date
    Sep 2004
    Posts
    6

    Re: RemoteHostIP snafoo

    The clientwinsock.localip and the ip given by the ipconfig command prompt on the laptop both give one address. The serverwinsock.remotehostip on the pc gives a different address. I am familiar with winsocks and how to set them up; this is a case where a machine thinks it's ip is one thing, but computers that it connects to think it's ip is a different thing. I checked, and the two computers have different subnet masks, that may be the problem.

    Roush

  4. #4
    PowerPoster
    Join Date
    Dec 2003
    Posts
    4,787

    Re: RemoteHostIP snafoo

    Quote Originally Posted by JRoush
    The clientwinsock.localip and the ip given by the ipconfig command prompt on the laptop both give one address. The serverwinsock.remotehostip on the pc gives a different address. I am familiar with winsocks and how to set them up; this is a case where a machine thinks it's ip is one thing, but computers that it connects to think it's ip is a different thing. I checked, and the two computers have different subnet masks, that may be the problem.

    Roush
    Hmm, sounds like a network issue.

    Hope you solve your problem, is this post now resolved? If so could you add the to your first post

  5. #5
    Junior Member
    Join Date
    Jan 2005
    Posts
    25

    Re: RemoteHostIP snafoo

    try putting the server on the laptop. Also what's this ipconfig thing? how do you find the ip straight from your computer?

  6. #6
    Banned dglienna's Avatar
    Join Date
    Jun 2004
    Location
    Center of it all
    Posts
    17,901

    Re: RemoteHostIP snafoo

    send email to yourself, and look there

  7. #7

    Thread Starter
    New Member
    Join Date
    Sep 2004
    Posts
    6

    Re: RemoteHostIP snafoo

    ipconfig is a dos command, you can use it in the command prompt. There are other ways of checking your IP via the network connections section on the control panel, but i use ipcondig because it's usually simpler to get to.

    **************************************************
    USAGE:
    ipconfig [/? | /all | /renew [adapter] | /release [adapter] |
    /flushdns | /displaydns | /registerdns |
    /showclassid adapter |
    /setclassid adapter [classid] ]

    where
    adapter Connection name
    (wildcard characters * and ? allowed, see examples)

    Options:
    /? Display this help message
    /all Display full configuration information.
    /release Release the IP address for the specified adapter.
    /renew Renew the IP address for the specified adapter.
    /flushdns Purges the DNS Resolver cache.
    /registerdns Refreshes all DHCP leases and re-registers DNS names
    /displaydns Display the contents of the DNS Resolver Cache.
    /showclassid Displays all the dhcp class IDs allowed for adapter.
    /setclassid Modifies the dhcp class id.

    The default is to display only the IP address, subnet mask and
    default gateway for each adapter bound to TCP/IP.

    For Release and Renew, if no adapter name is specified, then the IP address
    leases for all adapters bound to TCP/IP will be released or renewed.

    For Setclassid, if no ClassId is specified, then the ClassId is removed.

    Examples:
    > ipconfig ... Show information.
    > ipconfig /all ... Show detailed information
    > ipconfig /renew ... renew all adapters
    > ipconfig /renew EL* ... renew any connection that has its
    name starting with EL
    > ipconfig /release *Con* ... release all matching connections,
    eg. "Local Area Connection 1" or
    "Local Area Connection 2"
    **************************************************

  8. #8
    Banned dglienna's Avatar
    Join Date
    Jun 2004
    Location
    Center of it all
    Posts
    17,901

    Re: RemoteHostIP snafoo

    How do you view the IP address from Network Connections? (unless it is static?)

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