Hi

I have a VB5 application which will print to both dot matrix and laser printers. Gnerally works fine

However with HP laserjet 1020 print job is sent to printer. It appears in queue, the printer warms up and nothing else happens.

Sometimes the job dissappears from queue, othertimes it sits there and jams queue.

Anyone else expereinced this and can offer a solution please.

Thanks

Denis

Recommended Answers

All 3 Replies

Normally the programers display a option form before the print indicating buttons such as print, view, save,options etc. In options you have to design the code for user to select the available printers installed. Otherwise only the default printer will be select.

How you have used the Print Object is to be taken into account.
Please let me know the program code you have used for the printer object

Hi,

Thanks for your reply. I have now with the help of HP got to the botton of the problem. As a result I can recommend there email technical support, seems to work 24 hours per day max wait one hour from sending email to getting a response, minimum about ten minutes. No cost for it and no apparent limit to number of related questions. I had reponses coming back at 2am.

Here is solution, which also answers your question AV Manoharan.

I was using WIN API calls to control the printer. It appears that the newer cheaper printers now have no onboard processing, so therefore can not handle the API calls. All processing has to be done in the PC.

You can tell the difference in the printers because if you look at spec and find what they support, then the ones that support API calls support various flavours of PCL or similar, those that don't are described as 'host'. These can't be networked, though they can be shared on a network.

Hope this is clear - now I have to find another way of sending to printer from the program.... a few more late nights to come.

Dear Denis,
It is very strange that our VB has no print controls. Just note that after your program sends output to the printer, the job of your VB is over. That is when you give

Printer.EndDocument

in VB, the whole chunk is passed, not to the printer stright, but to the print spool. Here your windows intercept it without stright passing to the printer to print, rather, the windows intercepts the print commands within the chunk. The print spooler after intercepting these commands change the output before the printer can catch it. Here one major problem is that your windows spooler should know how to communicate with the attached printer. There are an array of printers supported by windows. Still as you have said there are certain cheap printers that is not supported by windows.

The ShowPrinter methode should be employed by a dialog box to help the user to select the installed printers on his/her computer.

Thankq, and don't spend sleepless nights over this. I will be somewhere arround you, to help.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.