473,406 Members | 2,312 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,406 software developers and data experts.

Using Winsock / TCP Client

Hello All,

I am using a winsock device to stream printer code to a printer. It works
well enough except one problem you may be able to help with.

When I establish a connection and stream code to the printer, it works
immediately, and the printer prints immediately.

I can stream code to the printer multiple times with no delays. However,
once I close the tcpClient, and re-open it, the printer does not print until
I shut down the VB.Net application.

I have tried multiple different places to close and reopen the tcpClient,
but so far, unless I keep it open for the duration of the application, I
lose the immediate printing until I shut down the application. I guess it
is sitting in a buffer somewhere, but I cannot find it.

Any suggestions?

Thanks in advance for your time.
Mark Breen
Ireland
Jan 31 '06 #1
1 2184
Mark,

You might be needing to dispose of the tcpClient fully prior opening a new
connection.

I ran into the same thing with a serial datastream. I had to completely
build and release (mySerialConn = nothing) the connection between sessions.
VB otherwise was trying to use objects that were in limbo. Everything would
run fine the first time but fail the second.

Just my $0.02

Tom
"Mark L. Breen" <ma********@nospam-gmail.com.off> wrote in message
news:%2****************@TK2MSFTNGP15.phx.gbl...
Hello All,

I am using a winsock device to stream printer code to a printer. It works
well enough except one problem you may be able to help with.

When I establish a connection and stream code to the printer, it works
immediately, and the printer prints immediately.

I can stream code to the printer multiple times with no delays. However,
once I close the tcpClient, and re-open it, the printer does not print
until I shut down the VB.Net application.

I have tried multiple different places to close and reopen the tcpClient,
but so far, unless I keep it open for the duration of the application, I
lose the immediate printing until I shut down the application. I guess it
is sitting in a buffer somewhere, but I cannot find it.

Any suggestions?

Thanks in advance for your time.
Mark Breen
Ireland

Jan 31 '06 #2

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

Similar topics

1
by: N.Naeem | last post by:
Hello all i need a solution to the following problem I have an application which listens to a port for incoming connections from a client via a Winsock. let's call this Winsock1 Upon a...
2
by: Dan | last post by:
I'm writing a simplistic telnet client in VB6 and I've run into a small snag. The program has a textbox to write in the string to be sent using ..SendData and has another textbox that displays...
1
by: Dom | last post by:
I'm new to c++. Just started learning it 24 hours ago. Am running into a compile problem. Please, no one waste the effort telling me to google it. I've been researching it for quite a while with no...
0
by: Björn Pedersen | last post by:
I'm having a tough time getting System.Net.Sockets to work with a server that's based around Winsock 6.0. For many reasons I can't write a new server because the server handles a number of client...
1
by: verge | last post by:
hello everyone! how's it going? like everyone in here im in need of some help and good friendship along the way...take a look at this: //MODIFIED SO IT DEALS WITH WINDOWS FTP USING ACTIVE...
1
by: Nicolas Ghesquiere | last post by:
Hello I have a problem with my current program. The meaning of the program is to allow users to login to a server to allow them to access the internet. My program communicates with a MS isa...
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: nitehawk416 | last post by:
I'm building a mud client, it connects through the winsock control to the server, and it gets the data, sends it back and displays it in a rich text box. I need a way to display the ansi colors that...
2
by: 000dreamsound000 | last post by:
Hi I am working on a security network camera system as part of a summer project of mine. The camera allows use of a TCP server for event configuration. I have coded a simple TCP server which beeps...
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
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
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
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

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.