Can we print using Qbasic
Yes, using the LPRINT command, though I think this is limited to printers connected to your computer through the parallel (LPT1) port.
LPRINT works just like PRINT. For example,
will print Hello, how are you today? on your paper.
As far as printing graphics and colors, I can't remember how to do it... and I'm not even sure if you can. Maybe one of these other nice people can fill us both in?
LPRINT works just like PRINT. For example,
Code: Select all
LPRINT "Hello, how are you today?"
As far as printing graphics and colors, I can't remember how to do it... and I'm not even sure if you can. Maybe one of these other nice people can fill us both in?
Printing graphics and colors requires you to know the escape codes of your printers manufacturer. Try to find them using google, then you can send these escape commands to the printer (using LPRINT as well, I thought) and it will execute the commands.Pete wrote:As far as printing graphics and colors, I can't remember how to do it... and I'm not even sure if you can. Maybe one of these other nice people can fill us both in?
The commands differ per printer however, so if you want to make a program that prints out graphics, note that only your printer and similar printers will be able to print, other printers will either print random garbage or returns errors.
Colour printing
I had an example ages ago that did it for IBM-compatible printers. These are rare to find now, but it's quite similiar these days.
It'll be hard to make it portable unfortunatly since every printer manufacturer likes to make unstandardised crap. Maybe if you found out how to put various printers in postscript mode (if it existed) you'd have some luck =P
-abionnnn
It'll be hard to make it portable unfortunatly since every printer manufacturer likes to make unstandardised crap. Maybe if you found out how to put various printers in postscript mode (if it existed) you'd have some luck =P
-abionnnn