I have an application in which i need to know when the user has plugged in or plugged out the ethernet cable to the system.
I have the adapter information within my application.
I tried using the device change notification with Registering the notification giving the guid for lan class. But this helps only when i either enable or disable the land adapter from my device manager.
Please help or provide pointers to some link.
Thanks in advance.
In my VC++ Socket programme I can connect to another system and transfer the data between them, the system are connected through LAN.
I want to know how can communicate with another system through Internet by socket programme(with out LAN ,through Internet).
(Like Server running in anywhere and client was Running anywhere they are connect through internet by Socket programme)
It should work exactly the same - your connect() call can specify 'www.codeproject.com' just as easily as it can specify '192.168.0.5' - if this does not seem to work, perhaps a small code sample showing how you try to connect to the remote server would help us see where the problem lies?
You shouldn't be facing any problem to connect to the Internet Server. But to Retrive or to send the Data on the Internet server you need to follow the Http protocol. that mean you first need to send the Http Header. That depends on the metod you are using. There are two Methods in Http, Http POST and Http GET.
Try to find out the header for that and Send it Before you send the data.
The Sample Header is as Follow. Try it if it works