473,406 Members | 2,208 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.

Printing on Dot-Matrix Printer, Stop and Restart

Hi,

i have made a project for printing fee receipt. Using Windows-XP, VBasic 6.0 & Ms-Access-97. i have designed a form for prinring receipts. m paper-size is 5x10. Two copies of bills in this size. one for student and other for fee clerk. while printing on dot-matrix, form get printed, but size is A4. My problem is
* how to change size to 5x10 (exactly half of printed paper width-wise)
* after printing on this size, stop the printer and not to eject
* Restarting fee receipt printing for next student on paper.

send code snippet.

Please ans. me and thanks
Jul 5 '07 #1
9 7800
Killer42
8,435 Expert 8TB
I think you should try playing with the properties of the Printer object in VB. It has properties like PaperSize, PaperBin and so on, which are probably relevant to your situation.
Jul 6 '07 #2
How u print the data through printer? using print #1 method or printer.print method?. If ur data is in english language, u will not get any problem, try print #1 method, open LPT1 (connect yr printer in LPT port) in write mode and transfer the data through print #1 method, everything will work, u will get speed and control over printer.
Jul 7 '07 #3
Hi,

i have made a project for printing fee receipt. Using Windows-XP, VBasic 6.0 & Ms-Access-97. i have designed a form for prinring receipts. m paper-size is 5x10. Two copies of bills in this size. one for student and other for fee clerk. while printing on dot-matrix, form get printed, but size is A4. My problem is
* how to change size to 5x10 (exactly half of printed paper width-wise)
* after printing on this size, stop the printer and not to eject
* Restarting fee receipt printing for next student on paper.

send code snippet.

Please ans. me and thanks




Thanks Sir,

i will apply your suggestions and inform you soon
Jul 7 '07 #4
How u print the data through printer? using print #1 method or printer.print method?. If ur data is in english language, u will not get any problem, try print #1 method, open LPT1 (connect yr printer in LPT port) in write mode and transfer the data through print #1 method, everything will work, u will get speed and control over printer.


Thanks Sir,

i will do that and reply you what happened,

ok bye.
Jul 7 '07 #5
Hi,

i have made a project for printing fee receipt. Using Windows-XP, VBasic 6.0 & Ms-Access-97. i have designed a form for prinring receipts. m paper-size is 5x10. Two copies of bills in this size. one for student and other for fee clerk. while printing on dot-matrix, form get printed, but size is A4. My problem is
* how to change size to 5x10 (exactly half of printed paper width-wise)
* after printing on this size, stop the printer and not to eject
* Restarting fee receipt printing for next student on paper.

send code snippet.

Please ans. me and thanks


HI
I M UTPAL


CAN U TAL ME HOW CAN WE DONE IN VB DOS PRINTING CASH RECEIPT
PRINTER AUTOMATICELY EJECT AND INISILYSE THE PRINTER
CAH U TALE ME ABOUT THER CODE.
Apr 10 '08 #6
3
hi, can you show that code on this forum so we can also know about print#1 method or printer.print method
please ... because i have same trouble
Aug 6 '09 #7
How u print the data through printer? using print #1 method or printer.print method?. If ur data is in english language, u will not get any problem, try print #1 method, open LPT1 (connect yr printer in LPT port) in write mode and transfer the data through print #1 method, everything will work, u will get speed and control over printer.
hi, can you show that code on this forum so we can also know about print#1 method or printer.print method
please ... because i have same problem

thanks
Aug 6 '09 #8
CyberSoftHari
487 Expert 256MB
@Gurbinder Kaur
You can code like this,
Expand|Select|Wrap|Line Numbers
  1.  
  2. On Error GoTo ErrTrap
  3.        Open LPT1 For Output As #1
  4.         Write #1, PrintString1
  5.         Write #1, PrintString2
  6.     Close #1
  7. 'exit method
  8. ErrTrap:
  9.     MsgBox Err.Description, vbCritical + vbOKOnly
  10.  
Pass PrintStrings between paper size.
Aug 6 '09 #9
Thanks about your response ...
But there is more complicate situation on my form.
I have data in subform and mainform, for example:

On mainform:
---------------------------------------------------------
Date: 08/13/2009 Name: Andrew
---------------------------------------------------------
On subform:
---------------------------------------------------------
Item 1
Item 2
Item 3
...
...
---------------------------------------------------------

What kind of syntax that i can use for that situation? (print #1 method or printer.print method)

Actually I already have the report for that form but the problem is the printer can't be stop eject after print for last line on dot matrix printer then make long distance from last line to end of paper size. Can I just stop the printer eject after the last line with VBA?
Aug 7 '09 #10

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

Similar topics

24
by: Markus Ernst | last post by:
Hi I have a title with a title gif: <h1><img src="mytitle.gif" alt="This is my title"></h1> So this is text-based browser and search-engine friendly and can be easily formatted with a style...
1
by: Dave Quigley[work] | last post by:
Im working on a printing module for a program that my company is writing and I am wondering if im working with printing the right way. From what I understand with the PrintDocument you get a...
3
by: Chrisitiaan | last post by:
Hi, I want to develop a 'truly' object oriented application, that is, my business logic objects handle the business logic (of course) and the persistence to a MS SQL server database. The user...
5
by: John Bowman | last post by:
Hi, I've been reading through the threads on using the WebBrowser control in C# app's and how to print it's contents. I've got that much working. However, the big problem is I can't figure out...
1
by: Dan Bass | last post by:
I've got a custom control that makes use of DrawString and DrawBezier, drawn from the graphics object passed by in the PaintEventArgs for the Paint event. I've not printed anything via c#...
2
by: Steffen Loringer | last post by:
Hi group, I like to print my ASP.NET page with the internet explorer. I added a panel (with a black border and blue as background) and a button to my page. If I press print in the Internet...
1
by: Nick | last post by:
Hi, I'm converting an existing VB/Access app into an ASP.Net Intranet app. Most of the conversion is pretty straight forward - except the printing! The old app prints mailing labels on Avery...
1
by: Uncle_Albert | last post by:
Hi all! Printing in VB6 used to be a doddle, however, as with many other things, this task has been made much harder in VB.Net! Can anyone point me in the direction of sample code, tutorials,...
3
by: Jay | last post by:
Hi, I have this problem with DataGrid printing. I have a page which contains only DataGrid. When i try to print the page, only 1st page contains the verticle and horizontal lines of the...
10
by: sophie_newbie | last post by:
Hi, I'm trying to write a piece of code that spawns a thread and prints dots every half second until the thread spawned is finished. Code is something like this: import threading class...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
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...
0
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...
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.