473,544 Members | 1,915 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Sending plain text to a printer port

1,272 Recognized Expert Top Contributor
I am trying to print UPS shipping labels using a Zebra label printer. Apparently these printers have the label form programmed into the firmware and all I have to do is send a particular string of text to the port the printer is connected to (USB) and voila, the printer makes the label correctly.

How do I send unformatted text to a printer port using MS Access? I've got version 2003 in a Win XP environment.

Thanks!
Jim
Nov 5 '07 #1
4 9614
ADezii
8,834 Recognized Expert Expert
I am trying to print UPS shipping labels using a Zebra label printer. Apparently these printers have the label form programmed into the firmware and all I have to do is send a particular string of text to the port the printer is connected to (USB) and voila, the printer makes the label correctly.

How do I send unformatted text to a printer port using MS Access? I've got version 2003 in a Win XP environment.

Thanks!
Jim
Try the following code to send unformatted Tetxt to a Local Printer at LPT1:
Expand|Select|Wrap|Line Numbers
  1. Open "LPT1" For Output As #1
  2. Print #1, "This is just a Test"
  3. Close #1
Nov 9 '07 #2
wvmitchell
42 New Member
Try the following code to send unformatted Tetxt to a Local Printer at LPT1:
Expand|Select|Wrap|Line Numbers
  1. Open "LPT1" For Output As #1
  2. Print #1, "This is just a Test"
  3. Close #1
I think that should be "LPT1:" notice the colon.
Nov 11 '07 #3
ADezii
8,834 Recognized Expert Expert
I think that should be "LPT1:" notice the colon.
Thanks for pointing that out to me.
Nov 11 '07 #4
FishVal
2,653 Recognized Expert Specialist
..... printer is connected to (USB) ......
I suppose that printer port is called "USBxxx" instead of "LPTx:". That should be checked in the printer properties.

Regards,
Fish.
Nov 11 '07 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

1
16685
by: Chuck Rittersdorf | last post by:
Hi There I am having a problem using the win32 API from VB6. I am trying to send a command string to a printer(zebra TLP 2742) on LPT1 using the folowing API functions CreateFile and WriteFile I have written C code which works fine, just the VB translation/port
0
1200
by: notregister | last post by:
Hi, i have trying to send a PCL file to a printer using the following codes, but the printer would normally hang for a long time after i have send the command, and i do not know what wrong with it, this are ample code i found in msdn, and yet it could not work, pls advise Thanks Public Function PrintChunkParallel(ByVal lPort As Long,...
4
4201
by: Schwarty | last post by:
I hope I posted this to the correct group. If not, please let me know and I will get it posted in the correct section. I have a web application developed in ASP.NET using C# for the code behind. I need to be able to print shipping labels from a web page within this application. The shipping label data is pulled from a 3rd party application...
2
3016
by: jabdulius | last post by:
Hi all, I'm trying to send a page using Perl via the WCTP protocol. For some reason, I cannot connect to the host "wctp.att.net/WCTP" (or any host for that matter). I figure it must be some server configuration that I need to set. I don't think it's a port problem b/c I'm able to send a page via WCTP using the same port using a stand-alone...
2
4407
by: hari | last post by:
Hi all, I need to automate printer command testing, prinetr supports parallel/ serial/USB.How can i send the commands from python to printer. I have got pyparallel, as am new to python, no idea how to work on it. Please give some tips,The comamnd to be sent to the printer is hex data "1B 40".please give a example,it will be grateful.
10
18179
by: sklett | last post by:
I'm trying to send some printer commands (ZPLII) to an attached USB printer using the SerialPort component. I didn't get very far at all. In fact I haven't gotten anywhere. The first problem I encountered is that a call to SerialPort.GetPortNames() returns an empty string. In other words, NO port names are returned. I'm not terribly...
0
2866
by: Charles Crawford | last post by:
Hi, This apparently is a common problem and I've yet to read a solution that actually works for my specific situation. I have a Zebra RW220 printer that I connect to via Bluetooth connection mapped to a serial port. The application I'm writing runs on a Windows Mobile 5 device, so there's no built in printer support and I have to use a...
0
3750
by: =?Utf-8?B?Q2hhcmxpZQ==?= | last post by:
Hi, This apparently is a common problem and I've yet to read a solution that actually works for my specific situation. I have a Zebra RW220 printer that I connect to via Bluetooth connection mapped to a serial port. The application I'm writing runs on a Windows Mobile 5 device, so there's no built in printer support and I have to use a...
31
12609
by: happyse27 | last post by:
Hi All, I am trying for weeks how to send email from windows pc, which from my gmail account to my hotmail account. Using net::smtp module sending email failed,Kindly assist. (for the item d it is working for normal email servers, but NOT with gmail server, I am very puzzled still!!) Codes(item c below) It keeps complaining and logs and...
0
7413
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7356
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
7597
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
1
7358
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7697
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
3397
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3396
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
980
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
650
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

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.