Solved

How do I switch between one HP laser printer and another in Dbase 3+?

Posted on 2014-07-21
7
326 Views
Last Modified: 2014-07-29
My client has a number of programs developed in Dbase 3+ which print in different fonts to an HP printer which is now outdated. He needs to upgrade to an HP 4000. The font control is done using hex codes directly sent to the printer.

Can this be changed to use some sort of font by name control?

Are the codes likely to be the same for older and newer HP printers?
0
Comment
Question by:dovidf
  • 4
  • 3
7 Comments
 
LVL 16

Expert Comment

by:DansDadUK
Comment Utility
>> ... The font control is done using hex codes directly sent to the printer ...

What you are probably referring to are font selection sequences.
Apart from the initial Escape character (the character with decimal code 27, or hexadecimal 1B), the sequences use ASCII text characters; since the Escape character is a non-graphic (control-code) character, it is usually referred to using a place-holder, such as <Esc>, or <esc>.


>> ... Can this be changed to use some sort of font by name control? ...

Not sure just what you are getting at here; your program could presumably have a built-in table mapping required font names to the equivalent PCL5 font selection sequence skeleton.


>> ... Are the codes likely to be the same for older and newer HP printers? ...

Depends how old the original one was.

LaserJet devices up to and including (I think) LaserJet 4 had various different mixes of printer-resident bitmap and Intellifont format scalable fonts.

More modern devices (except for the cheap 'host-based' devices) have a fairly consistent set of fonts, which (apart from the Line Printer bitmap fonts) use encapsulated TrueType scalable technology.

With most LaserJet printers, you can print off a Typeface List, which shows which fonts are available, and also shows the required font selection sequences.
With most devices, printing of the list can be invoked using the front panel menu system, or Embedded Web Server or Toolbox equivalents.
0
 
LVL 3

Author Comment

by:dovidf
Comment Utility
DansDadUK> What you are probably referring to are font selection sequences.

That is correct

DansDadUK> >> ... Can this be changed to use some sort of font by name control? ...

What I meant here is there some upgrade that can change the font by indicating font name and size such as in more modern programs.

The older printers are Laserjet II and Laserjet III. They use a font cartridge. Would the modern typeface list likely include some of the older printer fonts?

DansDadUK> Embedded Web Server or Toolbox equivalents

What does this mean? How can this be used?
0
 
LVL 16

Accepted Solution

by:
DansDadUK earned 500 total points
Comment Utility
>> ... What I meant here is there some upgrade that can change the font by indicating font name and size such as in more modern programs ...

I'm still not clear what you mean.
A PCL5 printer only understands PCL5 escape sequences.
How you refer to them in your 'program' (bearing in mind that I know nothing of DBase 3+) is up to you.

For example, you can define a byte array containing the font selection sequences required to select the 12-point size of the Arial font, and name the array Arial12, or fred , etc.
Then refer to the array by the name you've chosen when you come to copy the array contents to the printer.


>> ... The older printers are Laserjet II and Laserjet III. They use a font cartridge.
>> ... Would the modern typeface list likely include some of the older printer fonts?

The printer resident fonts on LJ II and LJ III are different to those on modern devices, although some of the old font selection sequences will possibly select similar looking fonts on the modern devices.

But use of font cartridges on the old machines implies that you are making use of 'special' fonts; to make these available on the newer printers, you'd need to:

Install equivalent external font add-ons (on SIMM, DIMM, compact flash, etc. depending on model) provided you can find one with the equivalent fonts.
or:  
Obtain PCL encapsulated soft font equivalents of the required fonts, and download these to the printer (usually every time it is powered up).


>> ... Embedded Web Server or Toolbox equivalents ... What does this mean? How can this be used?

For modern 'network' enabled models (usually those with 'n' or 'w' in the model name), you can point your browser at the TCP/IP address of the printer, and this should display the Embedded Web Server interface, which should provide you with the equivalent of the front panel menu system.

The Toolbox application is available with some non-network models to provide an equivalent of the EWS for printers connected via direct connection (parallel-port or USB).
0
Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

 
LVL 3

Author Comment

by:dovidf
Comment Utility
I am waiting to hear from the user which fonts he wants to emulate on the new machine.
0
 
LVL 3

Author Comment

by:dovidf
Comment Utility
The cartridge that they are currently using supports Helv Bold, tms roman medium, tms roman bold, tms roman italic medium, line printer medium.

There is smaller writing to the right of these fonts but I can't read it and have requested that they send me that information.
0
 
LVL 16

Expert Comment

by:DansDadUK
Comment Utility
Not having access to a LaserJet 4000 printer (which is hardly a new printer itself - it first came out in 1997), I'm not sure about Helvetic Bold, but I would imagine that the standard printer resident font list would include:

scalable Times Roman and/or Times New Roman and/or CG Times typefaces in Regular, Bold and Italic variants
bitmap (fixed size 16.67 characters-per-inch) Line Printer font

A PCL Typeface List generated by the LJ 4000 would confirm the identities (and font selection sequences) of the available printer-resident fonts, so that you can compare these with your old cartridge font details.
0
 
LVL 3

Author Closing Comment

by:dovidf
Comment Utility
Thanks for your help with this issue
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Suggested Solutions

Entity Framework is a powerful tool to help you interact with the DataBase but still doesn't help much when we have a Stored Procedure that returns more than one resultset. The solution takes some of out-of-the-box thinking; read on!
Whether you’re a college noob or a soon-to-be pro, these tips are sure to help you in your journey to becoming a programming ninja and stand out from the crowd.
In this fourth video of the Xpdf series, we discuss and demonstrate the PDFinfo utility, which retrieves the contents of a PDF's Info Dictionary, as well as some other information, including the page count. We show how to isolate the page count in a…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

772 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

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now