#1: Printing in bold through cobol Author: patnekar, Posted: Thu Dec 18, 2003 3:49 pm Hi,
My requirement is that I need to print certain information on paper. This information processed through a COBOL program and then sent to the printer.
I need to highlight certain lines in that information in bold. Could someone please help me out, as to how to go about doing this??
Thanks
Puru
#2: Author: Bithead, Location: Michigan, USAPosted: Thu Dec 18, 2003 4:05 pm The only thing that I can think of is to use the '+' carriage control which causes the printer to over-type. You would then have to print the same text twice.
#3: Author: kolusu, Location: San JosePosted: Thu Dec 18, 2003 5:09 pm patnekar,
Another option is AFP.AFP(Advanced Function Presentation) is a set of IBM licensed programs, together with user applications, that use the all-points-addressable concept to print on presentation devices. AFP includes creating,formatting, archiving, retrieving, viewing, distributing,and printing information.
If your shop has AFP then you can print in Bold, as it allows you select fonts for fields.
#4: Author: patnekar, Posted: Thu Dec 18, 2003 5:10 pm Thank you Kolusu and Bithead.
#5: Author: slade, Location: Edison, NJ USAPosted: Thu Dec 18, 2003 11:53 pm AIR, Bihead's approach will not work if the print data is SPOOLed. If you're printing directly to a print device, it should be OK.
Regards, Jack.
#6: Author: superk, Posted: Thu Jan 22, 2004 3:14 pm Puru, the "print/overstrike" carriage control '+', as stated earlier, will work to bold a print line, whether the printer is impact or is AFP controlled.
On the impact printer, a '+' carriage control, which essentially supresses the line-feed, will cause the print head to print the line, and then print over the same line, before advancing to the next print line.
On the AFP or other non-impact printer, the '+' will cause the printer to substitute a bold font for the existing standard font in use, also causing the bold line to print.
For advanced ADP and XEROX printers, there is a reserved print position, usually defined as the second byte of the output, immediately following the carriage-control, that is known as a TRC (Table Reference Character) byte. The TRC allows the programmer to select a font typeface from a table by inserting an appropriate reference character (0-F) within the print data. You must know the format of the TRC table font typeface assignments to use the TRC.
#7: Author: Mike Chantrey, Location: WansfordPosted: Tue Jan 27, 2004 5:45 am
Quote:
Puru, the "print/overstrike" carriage control '+', as stated earlier, will work to bold a print line, whether the printer is impact or is AFP controlled.
It doesn't work on any of our non-impact, non-AFP laser printers. The carriage return supression works, and if you overprint two different strings they appear overlaid. But if you overprint the same string to try to get bold you just get normal print. The only way I've been able to get bold on these printers is by sending the printer escape sequence (preceded by a special 'do not translate to ASCII' character). But this is not good since it is printer specific, and it doesn't work with JES prints since JES strips out the escape sequence for some reason (works from CICS OK).