winsock experts

This is a discussion on winsock experts within the Windows Programming forums, part of the Platform Specific Boards category; I'm hoping somebody can help me with my winsock program. I'm trying to get WriteFileEx to work with overlapped I/O ...

  1. #1
    Registered User
    Join Date
    Aug 2002
    Posts
    16

    winsock experts

    I'm hoping somebody can help me with my winsock program.

    I'm trying to get WriteFileEx to work with overlapped I/O on a socket. The trouble is, you can't specify a port or destination address with WriteFileEx, you can only specify the socket handle

    I've tried two different approaches to fix this:

    1) Tried writing a raw socket and filling in the IP Header and UDP header myself, then sending this off. That didn't seem to work
    2) Tried binding the socket to a sockaddr_in structure before the send. That didn't work either.

    Thing is, I'm not getting any errors. My completion routine is even called. It's just that the receiving program isn't getting the data.

    If anyone has ever done something like this, I'd appreciate a nudge in the right direction

    Thanks
    --Chorus

  2. #2
    train spotter
    Join Date
    Aug 2001
    Location
    near a computer
    Posts
    3,856
    What are the returns from WriteFileEx() and GetLastError() ?
    "Man alone suffers so excruciatingly in the world that he was compelled to invent laughter."
    Friedrich Nietzsche

    "I spent a lot of my money on booze, birds and fast cars......the rest I squandered."
    George Best

    "If you are going through hell....keep going."
    Winston Churchill

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Winsock issues
    By tjpanda in forum Windows Programming
    Replies: 3
    Last Post: 12-04-2008, 07:32 AM
  2. Winsock Messaging Program
    By Morgul in forum Windows Programming
    Replies: 13
    Last Post: 04-25-2005, 04:00 PM
  3. Where do I initialize Winsock and catch messages for it?
    By Lithorien in forum Windows Programming
    Replies: 10
    Last Post: 12-30-2004, 11:11 AM
  4. Winsock Problem
    By Noxir in forum C++ Programming
    Replies: 4
    Last Post: 07-18-2004, 10:50 AM
  5. winsock
    By pode in forum Networking/Device Communication
    Replies: 2
    Last Post: 09-26-2003, 12:45 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21