borderAndreaVB free resources for Visual Basic developersborder

borderAndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2007 Andrea Tincaniborder

AndreaVB | Forum | News | Downloads | Register | Help | Member List | Statistics | Search | PM | Profile

Print This Topic
Previous Topic (please tell me why my customer form gets hung up)Next Topic (Bitmap handle and DIB handle) New Topic New Poll Post Reply
AndreaVB Forum : VB General : Error Trapping for NETWORK Printer!
Poster Message
tubby735
Level: Protégé

Registered: 14-02-2006
Posts: 6

icon Error Trapping for NETWORK Printer!

Hi,

I've designed a VB6 application which worked fine for the las t several weeks, however yesterday the network printer for some reason was not available in the middle of the night. This cause my application to fail in the 'PrintIT Function' this function automatically prints out the previous day performance, then clear the data file to start a fresh day.

What happened was the print out never happened and the data was not cleared, so the application kept adding the current day to the previous day data.

Does anyone know how I can trap this network error, so that
the application can dump the info to a file instead and still clear collected data.

Regards
Tubby735

23-02-2006 at 09:59 AM
View Profile Send Email to User Show All Posts | Quote Reply
steve_w
Level: Moderator


Registered: 18-04-2003
Posts: 1156
icon Re: Error Trapping for NETWORK Printer!

Just a suggestion, but why not dump it into a file anyway. Then print the file.

Steve  

23-02-2006 at 12:04 PM
View Profile Send Email to User Show All Posts | Quote Reply
Goran
Level: Moderator

Registered: 16-05-2002
Posts: 1681
icon Re: Error Trapping for NETWORK Printer!

If you want to find if network printer is available, you could ping for it. Or you can usw WMI for this purpose, search for win32_Printer on MSDN

____________________________
If you find the answer helpful, please mark this topic as solved.

23-02-2006 at 09:21 PM
View Profile Send Email to User Show All Posts | Quote Reply
AndreaVB Forum : VB General : Error Trapping for NETWORK Printer!
Previous Topic (please tell me why my customer form gets hung up)Next Topic (Bitmap handle and DIB handle) New Topic New Poll Post Reply
Surf To:


Not Logged In? Username: Password: Lost your password?
Partners: Download Actual Software | Free Software Download
borderAndreaVB free resources for Visual Basic developersborder

borderAndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2007 Andrea Tincaniborder