套接字编程 [英] Socket Programming
问题描述
hi
我想为c/c ++编写用于IPv4协议的套接字程序.
但是我不知道如何开始以及从哪里开始.我在google上搜索了很多示例或给出的帮助,对我没有用..
如果您有任何知识或帮助.
关于上述问题,请帮我...
谢谢与问候
Nidhi
[edit date ="30/12/2010"]
Windows xp ...我需要将我的TCP/IP套接字转换为IPv4套接字..
这意味着我在局域网中使用的代码可以在局域网和广域网之间使用吗?
[/edit]
Nidhi,
请参考此链接.
http://www.winsocketdotnetworkprogramming.com/winsock2programming/winsock2advancedcode1a.html
hi 这篇关于套接字编程的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
请参考我先前的回答中的链接.转到该网页,阅读文章并使用提供的代码示例;他们提供解决问题所需的一切.
I want to write a program for sockets in c/c++ for IPv4 protocol.
but I''m not able understand how to start and where to start.I have searched google a lot example or help given their,is not useful for me..
If anyone of you have any knowledge or any help.
Please help me regarding above problem...
Thanks and Regards
Nidhi
[edit date="30/12/2010"]
Windows xp... I need to convert my TCP/IP socket to IPv4 socket..
Hi this means that the code which i used in my lan can be used in between a lan and a wan?
[/edit]Hi Nidhi,
Please refer this link.
http://www.winsocketdotnetworkprogramming.com/winsock2programming/winsock2advancedcode1a.htmlA Google search for "socket program" will reveal many samples including this one[^]. But note that IPv4 is not a protocol, merely a standard format for IP addresses. Socket programming is not dependent on IPv4 or IPv6, the same basic rules apply in either case.
Please refer to the link in my previous answer. Go to that web page, read the article and use the code samples provided; they give everything you need to resolve your issue.