Communication to TCP-IP Port

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello,
I am trying to find a way to communicate directly with a device on the
network (bar code printer) from within an Access 97 application. I have had
some success using the Internet Transfer Protocol control with FTP but that
is not really what I need. I need to be able to communicate with the printer
similar to using a COM port but using the network instead.

I am sure that it is something very simple that I am just missing.

Thanks for your help,
Ken
 
TCP is a protocol that uses the IP protocol that
uses the hardware link 'like a com port' (only
it uses a higher level protocol than com ports
do).

You can't communicate with TCP/IP or even with
IP like you do with a com port, because there is
no hardware TCP/IP device or IP device.

You can't communicate to a TCP/IP port like you
do to a Com port, because a com port is a physical
i/o address, but a TCP/IP port is a number in an
IP packet.

TCP and IP are provided by programs on your
computer. The interface to communicate with
these programs is called the WinSock or Windows
Sockets interface. You can communicate either
directly with the Windows API, or you can use
a Com/Active X control (a WinSock control) that
communicates with the Win API.

FTP and HTTP are protocols that run on top of
TCP on top of IP. I've never used the ITP control:
as far as I know Office does not include a WinSock
control or any control that exposes IP. PING is
another protocol like TCP that runs on top of IP:
any control that you can find that offers PING
will probably do what you are looking for.

(david)
 
Thanks David. I will look for a WinSock control or perhaps just use the API
directly and see if I can make that work.

Ken
 
Hi,

there are some very good examples of winsock code with/without the winsock
control, as there is a library that comes with IE called inet that provides
all the winsock functionality that you may require. Be warned winsock or
socket stuff can be quite complex. For some example code look at the vb code
on the planet source code http://www.pscode.com, type winsock in the search
at the top and select vb.

Hope it helps you, if you have any other questions post back here.
 
Back
Top