473,385 Members | 1,727 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

can I connect two computers using sockets

ngr
I am wanting to develop an application whereas two computers chat back and
forth.

The scenario is that I have a process running on both computers, which pass
information to each other as they go about processing their jobs -

I am aware that one computer has to act as server, and the other as client.
I did oncemanage to get something running with winsock, but now I am using
VB.NET2005 and sockets appear to have taken the place of winsock.

Please can anyone advise or point me to somewhere, so I know how to obtain a
constant connection and then pass information back and forth.

Thanks in advance for any feedback.

Tf

Apr 26 '07 #1
5 3306
"ngr" <ng*@tdrd.karoo.co.ukwrote in
news:m7*********************@eclipse.net.uk:
Please can anyone advise or point me to somewhere, so I know how to
obtain a constant connection and then pass information back and forth.
Standard sockets are bi-directional.

Take a look at TCPClient and Socket classes in .NET
Apr 26 '07 #2
I would suggest the System.Runtime.Remoting namespace. There are a number of
good articles on the subject and even a book or two. Start here:
http://msdn2.microsoft.com/en-us/web.../aa740645.aspx

"ngr" wrote:
I am wanting to develop an application whereas two computers chat back and
forth.

The scenario is that I have a process running on both computers, which pass
information to each other as they go about processing their jobs -

I am aware that one computer has to act as server, and the other as client.
I did oncemanage to get something running with winsock, but now I am using
VB.NET2005 and sockets appear to have taken the place of winsock.

Please can anyone advise or point me to somewhere, so I know how to obtain a
constant connection and then pass information back and forth.

Thanks in advance for any feedback.

Tf

Apr 26 '07 #3
=?Utf-8?B?Umljaw==?= <Ri**@discussions.microsoft.comwrote in
news:91**********************************@microsof t.com:
I would suggest the System.Runtime.Remoting namespace. There are a
number of good articles on the subject and even a book or two. Start
here: http://msdn2.microsoft.com/en-us/web.../aa740645.aspx

Remoting is pretty much obsoleted by WCF - if the OP is going to build a
new network application, WCF is better route to go.
Apr 26 '07 #4
On Apr 26, 9:16 am, "ngr" <n...@tdrd.karoo.co.ukwrote:
I am wanting to develop an application whereas two computers chat back and
forth.

The scenario is that I have a process running on both computers, which pass
information to each other as they go about processing their jobs -

I am aware that one computer has to act as server, and the other as client.
I did oncemanage to get something running with winsock, but now I am using
VB.NET2005 and sockets appear to have taken the place of winsock.

Please can anyone advise or point me to somewhere, so I know how to obtain a
constant connection and then pass information back and forth.

Thanks in advance for any feedback.

Tf
You want to get whats called a "crossover" cable. It looks like a
regular cat5 ethernet cable in all respects except it's wired a little
differently to go direct from network card to network card. Or you
can get a small cheap 4 port hub and connect both computers to it with
regular ethernet cables. Once you can ping across then you can load
IIS or whatever and do client/server or web or tcp or dcom, etc.
Apr 26 '07 #5
RickH <pa******@windcrestsoftware.comwrote in
news:11**********************@o40g2000prh.googlegr oups.com:
You want to get whats called a "crossover" cable. It looks like a
regular cat5 ethernet cable in all respects except it's wired a little
differently to go direct from network card to network card. Or you
can get a small cheap 4 port hub and connect both computers to it with
regular ethernet cables. Once you can ping across then you can load
IIS or whatever and do client/server or web or tcp or dcom, etc.
I found that the new Intel network cards on laptops in fact have auto-cross
over. The cross over cables maybe a thing of the past soon :-)
Apr 26 '07 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Kevin Sage | last post by:
For anyone who is having this problem and want to know the solution. Add this line of code before your connect method call. It loads up some config file that the code behind the scenes needs...
7
by: Michi Henning | last post by:
Hi, I'm using a non-blocking connect to connect to a server. Works fine -- the server gets and accepts the connection. However, once the connection is established, I cannot retrieve either the...
12
by: zhimin | last post by:
With C#, I had created two threads in one program. One is a TCP listener, and the other is TcpClient. After the Listener thread started, the client thread started try to connect to the listener,...
2
by: http://www.visual-basic-data-mining.net/forum | last post by:
Say i have declare a module for connection and two buttons... one button has the method connect() and the other has the method disconnect().... how do i actually connect after i had disconnect...
2
by: iwdu15 | last post by:
hey, i was wondering if 1) anyone could tell me whats wrong with my code, i did a little fixing to the msdn version fo this, or 2) how to make a simple program that will connect and listen for...
5
by: Pilence | last post by:
Hy!! Can someone tell me please how to do this type of work done by using C#......
14
by: DaTurk | last post by:
I am makeing a Multicast server client setup and was wondering what the difference is between Socket.Connect, and Socket.Bind. It may be a stupid question, but I was just curious. Because I...
5
by: ngr | last post by:
I am wanting to develop an application whereas two computers chat back and forth. The scenario is that I have a process running on both computers, which pass information to each other as they go...
0
by: Qui Sum | last post by:
I write ip/port scanner so users using search on our LAN know if the particular ftp is online or not. The class I write has the following structure: public class IPScanner { public...
3
by: Brian Odsgaard | last post by:
Hi all I'm going to build a simple multiplayer game. The task is to create a game that runs on multiple computers on a LAN. I want to create a solution that don't need a server running on a...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.