Solved

how to get a dot-matrix printer as fast as it is in DOS

Posted on 2004-10-11
10
485 Views
Last Modified: 2010-03-13
Greetings all!
My installation has 5 Seikosha BP5870 printers which print very fast from my DOS programmes.
I have installed the printer and am printing the reports from my Windows VB app, but Windows insists on printing in graphics mode, printing each line twice or more - for perfect clarity  o:{

I have set the quality to draft , and tried adjusting the Dithering and Resolution, but all to no avail.

Is there any way to get the printer just printing text in the good, ol' fashioned way?

Regards
Tony
0
Comment
Question by:pitwood
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
10 Comments
 
LVL 9

Expert Comment

by:Shahid Thaika
ID: 12280042
Is the program which is insisting on you choosing the best quality, you own vb app or someone else's. If someone else's, then he has probably written a poor app. If it is your vb app, you could try setting reference to 'Microsoft Common Dialog' controls and call the ShowPrinter function. Alternatively, you could just say...

Printer.PrintQuality = vbPRPQDraft or
Printer.PrintQuality = vbPRPQHigh or
Printer.PrintQuality = vbPRPQLow, etc...

Hope this answers your question
0
 
LVL 3

Expert Comment

by:Noel_Castillo
ID: 12283355
If you are using the printer object in vb. that is:
Printer.Print ........
....
....
Printer.EndDoc

then there should be no problem. try installing a generic text(make it default) instead of the actual printer driver. and you'll find your printer printing the old fashion way. (dont forget to set the font in the printer console ok? make it draft)


but if you're using a report writer like crystal report. we have the same problem and still seeking for an answer.
:)
0
 
LVL 7

Expert Comment

by:Enlade
ID: 12283451

Boy, I used to work for Seikosha Tech Support nearly 20 years ago.  Didn't think I would ever hear that name again after all these years.

I think that you discribed the problem correctly.  When windows prints to the Printer object it prints in graphics mode on those old dot matrix printers.  What you need is to write directly to the printer port (LPT1:) instead of using the Printer object.  However, I don't know if that is as easy as it used to be in VB.  I can probably find out for you, but probably someone else will be able to answer the question faster.  If not, then I'll look for something.

0
MS Dynamics Made Instantly Simpler

Make Your Microsoft Dynamics Investment Count  & Drastically Decrease Training Time by Providing Intuitive Step-By-Step WalkThru Tutorials.

 
LVL 7

Expert Comment

by:Enlade
ID: 12283474

Maybe try something like this:

Open "LPT1" For Output as #1

Print #1, "Hello World!!!"

Close #1

0
 
LVL 7

Expert Comment

by:Enlade
ID: 12283483

I just realized that I can't test anything since I have an Network printer and nothing connected to my LPT (PRN) port.  So, all I can do is suggest stuff to try (like the above).  Sorry.

0
 
LVL 7

Expert Comment

by:Enlade
ID: 12283494

Also try "LPT1:" with the colen.  Sometimes it requires a colen to work.

So, try

Open "LPT1:" For Output As #1

.....

0
 
LVL 7

Expert Comment

by:Enlade
ID: 12283500

Oh, you know I could probably redirect LPT1 to my Network printer and test it that way.  Let me try that....hold up...
0
 
LVL 7

Accepted Solution

by:
Enlade earned 500 total points
ID: 12283549

Yea...that works.  You just need to use Open and Print.  If you want to use fonts or bold or italic or any other text format then you will need to use the printer control codes to set those on your printer.  For instance, if you want Elite type font you would look up the control code in the back of your Seikosha manual for Elite font (its something like 27, 69 though I don't remember so look it up).  Still, lets say it is 27, 69 so I can show you how to make use of that control code.  You would do something like this.

Open "LPT1:" For Output As #1

Print #1, Chr(27) & Chr(69) & "Hello World!!!!"

Close #1

Hope that helps; though, I might add that printing directly to the printer is not all that common an approuch to printing.  But if you have an old dot matrix printer then it is probably the solution you are looking for.
0
 

Author Comment

by:pitwood
ID: 12284765
Thanks, guys, for your speedy responses.

Enlade has given me the answer - the one I feared!  o:}

I will have to write a completely different section for my printing routines (lots of work!) to allow for the dot-matrix printers - basically just the same as I did in my old DOS Basic programmes.

I'll check it out and report back

Regards
Tony
0
 

Author Comment

by:pitwood
ID: 12363016
Muchos gracias, Eldane,

It works a dream

Regards
Tony
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The debugging module of the VB 6 IDE can be accessed by way of the Debug menu item. That menu item can normally be found in the IDE's main menu line as shown in this picture.   There is also a companion Debug Toolbar that looks like the followin…
Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

688 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question