Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

C++ sys.h and net.h header files.

Posted on 2004-09-12
9
Medium Priority
?
437 Views
Last Modified: 2012-06-27
Dear Expert,

I want to develop applications which depend on networking. I have got books in which sample networking applications uses net.h and sys.h C++ header files. In my C++ these files are not there. So, I am unable to compile those programs and learn network programming.

Kindly help me in getting these header files. If download of them is available on net then please give the URL.

Thank You.

VM.
0
Comment
Question by:vikrant10
  • 4
  • 3
9 Comments
 
LVL 45

Expert Comment

by:sunnycoder
ID: 12041435
Hi vikrant10,

which platform and compiler are you using ?

Sunnycoder
0
 

Author Comment

by:vikrant10
ID: 12041468
Dear sunnycodeer,

I am using windows platform. Compiler is Turbo C++(don't remember actual version).

VM.
0
 
LVL 45

Expert Comment

by:sunnycoder
ID: 12041476
Turbo C++ is for DOS ... Network programming in DOS may not be pretty ...

I suggest that you get a newer compiler ... cygwin + windows port of gcc is one good option ... another will be something like devshed C++ or VC++
0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 

Author Comment

by:vikrant10
ID: 12041499
Dear sunnycoder,

I have got Visual Studio 6. Visual C++ is installed with it. But it doesn't have those header files. Can u give me the URL of any download site.

Help me.


VM.
0
 
LVL 45

Expert Comment

by:sunnycoder
ID: 12041504
vikrant10,

For VC++, you need to include winsock.h file
check these links
http://tangentsoft.net/wskfaq/
http://www.hal-pc.org/~johnnie2/winsock.html

Sunnycoder
0
 

Author Comment

by:vikrant10
ID: 12109941
Dear sunnycoder,

As u have suggested, I have included winsock.h file in my C coding in Visual C++. The program has not compiled with zero errors. But on building it is displaying linking errors. For eg. on lines containing gethostbyname, shutdown etc. What might be problem ?

Please help.

VM.
0
 
LVL 45

Accepted Solution

by:
sunnycoder earned 500 total points
ID: 12110010
make sure that winsock.dll is in the linker's path
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article is meant to give a basic understanding of how to use R Sweave as a way to merge LaTeX and R code seamlessly into one presentable document.
This article will show, step by step, how to integrate R code into a R Sweave document
The viewer will learn how to implement Singleton Design Pattern in Java.
The viewer will learn how to pass data into a function in C++. This is one step further in using functions. Instead of only printing text onto the console, the function will be able to perform calculations with argumentents given by the user.
Suggested Courses

927 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question