Click here to Skip to main content
15,905,325 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
i want one socket to listen a tcp port and save recieve data in a file. printer send data to tcp port instead com or lpt.socket listen this port and save data (in string)in other file.plese guide me.
Posted

You need to write a driver level application , your driver application will install a driver on the system , when someone prints on this printer the data comes to ur application , then u can do whatever you want to do with the data
 
Share this answer
 
You do not actually need to write a driver level app as any simple program can listen to a socket and save the data sent to it. However you may have difficulties interpreting what is sent to you if it is destined for a printer device.

Take a look at some of the articles on socket programming here on CodeProject for some samples.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900