Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

I'm reading through a Winsock book for C++ and it says that in order to use winsock2 I need to reference the ws2_32.lib library file. How do I do this with the .Net compiler?

 

"When compiling your application with WINSOCK2.H, you should link with WS2_32.LIB library"

 

That's what my book says.

 

 

Thanks in advance.

Posted
Are you using C++? If you're using C++ I'd imagine you link it like you would any other C++ project. If you're using .NET I believe there's a class library in the .NET framework that encapsulates winsock functionality. If not try the import attribute.
Gamer extraordinaire. Programmer wannabe.
Posted

PlausiblyDamp > Umm, I don't see the Linker option? I'm using the Visual Studio .Net compiler if that makes any difference?

 

And yes I'm using C++.

  • *Experts*
Posted
It should be there like PlausiblyDamp said, right click your project, select properties, on the left there is a treeview with options, there should be one that Configuration Properties, expand that, and then expand one that says linker, then click on Advanced on the expanded list. And there should be an Import Library option on the right.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...