TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
p df
NA
1
0
Network, multi Interface, socket
Apr 2 2008 5:33 AM
Hello,
I have, on a PC, two Network Adapters.
I need to test the quality of these interfaces, with a cross link.
I have written a small program in C# with a client socket and a server socket.
But I want to be sure that exchange is going on the cable, and NOT inside the network layers of the PC.
So I want to bind the client socket and the server socket each to one of the interfaces.
The function I want to use is in the following code :
Socket xPortSend;
//...
byte[] AdapterId = ????
int iRet = xPortSend.
IOControl
(
IOControlCode.BindToInterface
, AdapterId, null );
1) I don't know how to find the Adapter Id of each network interface ?
2) The parameter need to be a byte[] array : how to convert ?
2) Which is the exact synthax to use with the function "IOControl" in this specific case (there are on the net only samples for RecevAll value) ?
Some samples on this call will be very helpfull ?
Best regards.
Reply
Answers (
0
)
How to call a c++ function from c# program
How to use Data Sets?